Skip to content

Commit

Permalink
rewrite hard
Browse files Browse the repository at this point in the history
  • Loading branch information
illarionov committed Jul 27, 2013
1 parent cf5a65a commit 09e154a
Show file tree
Hide file tree
Showing 22 changed files with 3,082 additions and 1,301 deletions.
17 changes: 9 additions & 8 deletions .classpath
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="gen"/>
<classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
<classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
<classpathentry kind="output" path="bin/classes"/>
</classpath>
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
<classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="gen"/>
<classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.DEPENDENCIES"/>
<classpathentry kind="output" path="bin/classes"/>
</classpath>
291 changes: 291 additions & 0 deletions .settings/org.eclipse.jdt.core.prefs

Large diffs are not rendered by default.

61 changes: 61 additions & 0 deletions .settings/org.eclipse.jdt.ui.prefs
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
cleanup_settings_version=2
eclipse.preferences.version=1
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
formatter_profile=_Android
formatter_settings_version=12
org.eclipse.jdt.ui.ignorelowercasenames=true
org.eclipse.jdt.ui.importorder=android;com;dalvik;gov;junit;libcore;net;org;java;javax;
org.eclipse.jdt.ui.ondemandthreshold=99
org.eclipse.jdt.ui.staticondemandthreshold=99
sp_cleanup.add_default_serial_version_id=true
sp_cleanup.add_generated_serial_version_id=false
sp_cleanup.add_missing_annotations=true
sp_cleanup.add_missing_deprecated_annotations=true
sp_cleanup.add_missing_methods=false
sp_cleanup.add_missing_nls_tags=false
sp_cleanup.add_missing_override_annotations=true
sp_cleanup.add_missing_override_annotations_interface_methods=true
sp_cleanup.add_serial_version_id=false
sp_cleanup.always_use_blocks=true
sp_cleanup.always_use_parentheses_in_expressions=false
sp_cleanup.always_use_this_for_non_static_field_access=false
sp_cleanup.always_use_this_for_non_static_method_access=false
sp_cleanup.convert_to_enhanced_for_loop=false
sp_cleanup.correct_indentation=false
sp_cleanup.format_source_code=false
sp_cleanup.format_source_code_changes_only=false
sp_cleanup.make_local_variable_final=false
sp_cleanup.make_parameters_final=false
sp_cleanup.make_private_fields_final=true
sp_cleanup.make_type_abstract_if_missing_method=false
sp_cleanup.make_variable_declarations_final=false
sp_cleanup.never_use_blocks=false
sp_cleanup.never_use_parentheses_in_expressions=true
sp_cleanup.on_save_use_additional_actions=true
sp_cleanup.organize_imports=true
sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
sp_cleanup.remove_private_constructors=true
sp_cleanup.remove_trailing_whitespaces=true
sp_cleanup.remove_trailing_whitespaces_all=true
sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
sp_cleanup.remove_unnecessary_casts=true
sp_cleanup.remove_unnecessary_nls_tags=false
sp_cleanup.remove_unused_imports=true
sp_cleanup.remove_unused_local_variables=false
sp_cleanup.remove_unused_private_fields=true
sp_cleanup.remove_unused_private_members=false
sp_cleanup.remove_unused_private_methods=true
sp_cleanup.remove_unused_private_types=true
sp_cleanup.sort_members=false
sp_cleanup.sort_members_all=false
sp_cleanup.use_blocks=false
sp_cleanup.use_blocks_only_for_return_and_throw=false
sp_cleanup.use_parentheses_in_expressions=false
sp_cleanup.use_this_for_non_static_field_access=false
sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
sp_cleanup.use_this_for_non_static_method_access=false
sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
43 changes: 18 additions & 25 deletions AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
Copyright (C) 2010, 2011, 2012, 2013 Herbert von Broeuschmeul
Copyright (C) 2010, 2011, 2012, 2013 BluetoothGPS4Droid Project
Copyright (C) 2011, 2012, 2013 UsbGPS4Droid Project
Copyright (C) 2013 Alexey Illarionov
This file is part of UsbGPS4Droid.
Expand All @@ -24,17 +25,20 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.broeuschmeul.android.gps.usb.provider"
android:versionCode="127"
android:versionName="@string/versionName">
android:versionName="1.0 beta2">

<uses-feature android:name="android.hardware.usb.host" />
<uses-sdk android:targetSdkVersion="16" android:minSdkVersion="12" />
<uses-sdk android:targetSdkVersion="18" android:minSdkVersion="12" />

<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION" />

<application android:icon="@drawable/ic_launcher_bluegps" android:label="@string/app_name" android:allowClearUserData="true">
<activity android:name="org.broeuschmeul.android.gps.bluetooth.provider.BluetoothGpsActivity"
<application
android:icon="@drawable/ic_launcher_bluegps"
android:label="@string/app_name"
android:allowBackup="true" >
<activity android:name=".UsbGpsActivity"
android:label="@string/app_name"
android:launchMode="singleTask" >
<intent-filter>
Expand All @@ -46,28 +50,17 @@
</intent-filter>
<meta-data android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" android:resource="@xml/device_filter" />
</activity>

<!--
<service android:name=".BluetoothGpsProviderService" android:enabled="true" android:exported="true" android:process=":BluetoothGpsProviderService" >
-->
<service android:name="org.broeuschmeul.android.gps.bluetooth.provider.BluetoothGpsProviderService" android:enabled="true" android:exported="true" >

<service
android:name=".UsbGpsProviderService"
android:exported="false" >
<intent-filter>
<action android:name="org.broeuschmeul.android.gps.usb.tracker.nmea.intent.action.START_TRACK_RECORDING">
<category android:name="android.intent.category.DEFAULT" />
</action>
<action android:name="org.broeuschmeul.android.gps.usb.tracker.nmea.intent.action.STOP_TRACK_RECORDING">
<category android:name="android.intent.category.DEFAULT" />
</action>
<action android:name="org.broeuschmeul.android.gps.usb.provider.nmea.intent.action.START_GPS_PROVIDER">
<category android:name="android.intent.category.DEFAULT" />
</action>
<action android:name="org.broeuschmeul.android.gps.usb.provider.nmea.intent.action.STOP_GPS_PROVIDER">
<category android:name="android.intent.category.DEFAULT" />
</action>
<action android:name="org.broeuschmeul.android.gps.usb.provider.nmea.intent.action.CONFIGURE_SIRF_GPS">
<category android:name="android.intent.category.DEFAULT" />
</action>
</intent-filter>
<action android:name="org.broeuschmeul.android.gps.usb.tracker.nmea.intent.action.START_TRACK_RECORDING" />
<action android:name="org.broeuschmeul.android.gps.usb.tracker.nmea.intent.action.STOP_TRACK_RECORDING" />
<action android:name=".nmea.intent.action.START_GPS_PROVIDER" />
<action android:name=".nmea.intent.action.STOP_GPS_PROVIDER" />
<action android:name=".nmea.intent.action.CONFIGURE_SIRF_GPS" />
</intent-filter>
</service>

</application>
Expand Down
2 changes: 1 addition & 1 deletion project.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
# project structure.

# Project target.
target=android-16
target=android-18
14 changes: 7 additions & 7 deletions res/layout/about.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
>
<LinearLayout
Expand All @@ -43,10 +43,10 @@
android:text="@string/about_version"
/>
<TextView
android:id="@+id/about_version"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/about_text"
android:text="@string/versionName"
/>
</LinearLayout>
<!--
Expand All @@ -63,12 +63,12 @@
style="@style/about_text"
android:text="@string/about_app_desc"
/>

<TextView
android:id="@+id/about_license"
style="@style/about_text"
android:text="@string/about_license"
android:autoLink="none"
/>
android:id="@+id/about_license"
style="@style/about_text"
android:text="@string/about_license" />

<TextView
android:id="@+id/about_sources"
style="@style/about_text"
Expand Down
2 changes: 0 additions & 2 deletions res/values/constants.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@
-->

<resources>
<string name="versionName">beta 1</string>

<string name="pref_start_gps_key">startGps</string>
<string name="pref_gps_location_provider_key">gpsLocationProviderKey</string>
<string name="pref_replace_std_gps_key">replaceStdtGps</string>
Expand Down
4 changes: 3 additions & 1 deletion res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@
<string name="pref_mock_gps_name_title">Mock location provider name</string>
<string name="pref_mock_gps_name_summary">Usb GPS name: %s</string>
<string name="pref_connection_retries_title">Connection retry number</string>
<string name="pref_connection_retries_summary">Number of attempts before exiting: %s</string>
<plurals name="pref_connection_retries_summary">
<item quantity="other">Number of attempts before exiting: %s</item>
</plurals>
<string name="pref_recording_title">Enable/Disable NMEA log</string>
<string name="pref_recording_summary_off">Track recording is off</string>
<string name="pref_recording_summary_on">Track recording is on</string>
Expand Down
11 changes: 9 additions & 2 deletions res/xml/device_filter.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<usb-device vendor-id="1659" product-id="8963" />
<resources>
<!-- Prolific -->
<usb-device vendor-id="1659" product-id="8963" /> <!-- 0x067b 0x2303 PL2303 Serial -->
<usb-device vendor-id="1659" product-id="4660" /> <!-- 0x067b 0x1234 DCU-11 Phone Cable -->
<usb-device vendor-id="21362" product-id="8963" /> <!-- 0x5372 0x2303 Prolific2 PL2303 -->

<!-- Generic comunnication device with Abstract Control Model subclass -->
<usb-device class="2" subclass="0" protocol="0" />

</resources>
3 changes: 1 addition & 2 deletions res/xml/pref.xml
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,7 @@
android:key="@string/pref_connection_retries_key"
android:title="@string/pref_connection_retries_title"
android:defaultValue="@string/defaultConnectionRetries"
android:inputType="numberDecimal"
android:summary="@string/pref_connection_retries_summary" />
android:inputType="numberDecimal" />
</PreferenceScreen>
<CheckBoxPreference
android:enabled="true"
Expand Down
Loading

0 comments on commit 09e154a

Please sign in to comment.