diff --git a/OsmAnd/AndroidManifest.xml b/OsmAnd/AndroidManifest.xml
index d523ab0dc2..cc91fb289b 100644
--- a/OsmAnd/AndroidManifest.xml
+++ b/OsmAnd/AndroidManifest.xml
@@ -1,895 +1,1071 @@
+ xmlns:tools="http://schemas.android.com/tools"
+ package="net.osmand.plus"
+ android:installLocation="auto">
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
-
+
+
+
+
-
-
-
-
-
-
-
+
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+ https://stackoverflow.com/a/31028507/4654078
+ -->
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
-
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
-
-
-
-
-
+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-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
+
-
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+
-
-
-
+
\ No newline at end of file
diff --git a/OsmAnd/res/drawable/fab_extended_blue_idle.xml b/OsmAnd/res/drawable/fab_extended_blue_idle.xml
new file mode 100644
index 0000000000..38d7efd49e
--- /dev/null
+++ b/OsmAnd/res/drawable/fab_extended_blue_idle.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/OsmAnd/res/drawable/fab_extended_blue_pressed.xml b/OsmAnd/res/drawable/fab_extended_blue_pressed.xml
new file mode 100644
index 0000000000..fecb5efccc
--- /dev/null
+++ b/OsmAnd/res/drawable/fab_extended_blue_pressed.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/OsmAnd/res/drawable/fab_extended_drawable.xml b/OsmAnd/res/drawable/fab_extended_drawable.xml
new file mode 100644
index 0000000000..9d90401dba
--- /dev/null
+++ b/OsmAnd/res/drawable/fab_extended_drawable.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/OsmAnd/res/layout/activity_profile_settings.xml b/OsmAnd/res/layout/activity_profile_settings.xml
new file mode 100644
index 0000000000..0e850d0149
--- /dev/null
+++ b/OsmAnd/res/layout/activity_profile_settings.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/OsmAnd/res/layout/profile_list_item.xml b/OsmAnd/res/layout/profile_list_item.xml
new file mode 100644
index 0000000000..d193c7b16c
--- /dev/null
+++ b/OsmAnd/res/layout/profile_list_item.xml
@@ -0,0 +1,84 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/OsmAnd/res/layout/profiles_list_fragment.xml b/OsmAnd/res/layout/profiles_list_fragment.xml
new file mode 100644
index 0000000000..29b549104f
--- /dev/null
+++ b/OsmAnd/res/layout/profiles_list_fragment.xml
@@ -0,0 +1,45 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/OsmAnd/res/values/sizes.xml b/OsmAnd/res/values/sizes.xml
index 87d3b0a278..599e61f216 100644
--- a/OsmAnd/res/values/sizes.xml
+++ b/OsmAnd/res/values/sizes.xml
@@ -327,4 +327,9 @@
0.01
1.2
+
+ 64dp
+ 20dp
+ 18dp
+
\ No newline at end of file
diff --git a/OsmAnd/res/values/strings.xml b/OsmAnd/res/values/strings.xml
index d07d048d45..cba13a36df 100644
--- a/OsmAnd/res/values/strings.xml
+++ b/OsmAnd/res/values/strings.xml
@@ -1,16 +1,18 @@
-
+ -->
+ Select the profiles to be visible in the app.
+ Application profiles
Degrees
Milliradians
Angular measurement units
@@ -133,7 +135,7 @@
%1$s / month
%1$.2f %2$s / month
Save %1$s.
- Current subscription
+ Current subscription
Renews monthly
Renews quarterly
Renews annually
@@ -154,23 +156,23 @@
Node or way cannot be found.
No search results?\nGive us feedback
+ • Fixed crash on startup that occurred on some devices\n\n
+ • New Markers feature: Display already traversed markers\n\n
+ • Search history now shows previously searched categories\n\n
+ • Fixed crash on startup that occurred with non-latin maps\n\n
+ • Improve rendering speed issues on Android 8.0 devices\n\n
+ • Support for polygon (non-amenity) objects editing\n\n
+ • Measure distance: Add \"Measure\" button to Actions in the context menu\n\n
+
+ • Navigation: Fix progress bar, fast swapping of the start and end point of the route\n\n
+ • Map markers: Fix turning on/off groups, ability to hide markers from the map\n\n
+ • OSM Edit: Ability to edit tags for non-point objects and ways, fix missing comments on notes, backup of edits\n\n
+ • Improve Wikipedia and Wikivoyage parsing, updated files are already available\n\n
+ • Context menu: Fix transport shields color in the night mode, fix additional menu sizes\n\n
+ • Boat navigation: Support for waterway fairway\n\n
+ • Other bugfixes\n\n
+
Committing way…
Increase search radius to %1$s
\"%1$s\", as well as your location.
@@ -215,9 +217,9 @@
Paid app
Paid plugin
New Wikivoyage data available, update it to enjoy.
- Download Wikivoyage travel guides to view articles about places around the world without a connection to the Internet.
- Update available
- Download file
+ Download Wikivoyage travel guides to view articles about places around the world without a connection to the Internet.
+ Update available
+ Download file
The free worldwide travel guide anyone can edit.
Travel guides are currently based on Wikivoyage. Test all features during open beta testing for free. Afterwards, travel guides will be available to subscribers of OsmAnd Unlimited and owners of OsmAnd+.
You can and should edit any article on Wikivoyage. Share knowledge, experience, talent, and your attention
@@ -277,16 +279,16 @@
Enter longitude
Enter latitude
Enter latitude and longitude
- DD°MM′SS″
- DD.DDDDDD°
- DD.DDDDD°
- DD°MM.MMMM′
- DD°MM.MMM′
- E
- W
- S
- N
- Optional point name
+ DD°MM′SS″
+ DD.DDDDDD°
+ DD.DDDDD°
+ DD°MM.MMMM′
+ DD°MM.MMM′
+ E
+ W
+ S
+ N
+ Optional point name
Nearby routes within
Within
Type the filename.
@@ -326,12 +328,12 @@
GPX file with coordinates and data of the selected notes.
GPX file with coordinates and data of all notes.
+ • New: Support for global offline travel guides. Referenced locations are linked to the map. Initial data from Wikivoyage.\n\n
+ • Wikipedia: New look, active links, images now supported\n\n
+ • Open Track UI: Support for waypoint groups\n\n
+ • Map markers: Import of selected groups from GPX files, coordinate input, new look\n\n
+ • OsmAnd Live subscription now supports all OsmAnd features\n\n
+
Modify the search query.
Actions
Marker
@@ -384,12 +386,12 @@
Import as GPX file
Import as Favorites
Import file
- Wrong input
- Enter new name
- Back
- View
- Waypoints added to map markers
- Wrong format
+ Wrong input
+ Enter new name
+ Back
+ View
+ Waypoints added to map markers
+ Wrong format
Road
Show map
Route calculated
@@ -618,41 +620,41 @@
Show depth contours and points.
Nautical depth contours
+ \u2022 New feature: Quick action button\n\n
+ \u2022 Improved touch screen gesture response (e.g. concurrent panning and zooming)\n\n
+ \u2022 New map fonts covering more locales\n\n
+ \u2022 Support TTS for regional language variants (and accents)\n\n
+ \u2022 Visibility enhancements in several map styles and Wikipedia\n\n
+ \u2022 Support Open Location Code (OLC)\n\n
+ \u2022 Display elevation, slope, and speed profile for recorded GPX tracks and calculated routes\n\n
+ \u2022 \"Driving style\" setting and logic improvements for bicycle routing\n\n
+ \u2022 Altitude data settings for bicycle routing\n\n
+ \u2022 Several other improvements and bug fixes\n\n
+ and more…
+
+ \u2022 Mapillary plugin with street-level imagery\n\n
+ \u2022 Ruler widget for distance measurement\n\n
+ \u2022 GPX split intervals with detailed info about your track\n\n
+ \u2022 Other improvements and bug fixes\n\n
+
+ \u2022 Completely reworked map markers with directional lines and route planning\n\n
+ \u2022 Measure distance tool offering snap to road feature and saving points as track\n\n
+ \u2022 OsmAnd Live: Bug fixes, fresh data on the server every 30 minutes, updates implemented into the navigation\n\n
+
+ \u2022 Updated the context menu: Show when the POI opens / closes\n\n
+ \u2022 Transport menu: all available routes are now at the top\n\n
+ \u2022 Wikipedia: added the button to open the original article, updated the appearance of articles\n\n
+ \u2022 Route: added possibility to swap start and end points in one tap\n\n
+ \u2022 Notes: added sorting by type and date\n\n
+ \u2022 OSM edits: Show an icon and a name of the POI category, display completed actions\n\n
+ \u2022 New quick coordinate input screen for quick markers creation\n\n
+ \u2022 Detection of stop signs now considers driving direction\n\n
+ \u2022 New algorithm providing meaningful ascent/descent values for GPX tracks\n\n
+ \u2022 Terrain (ascent) aware hiking time (Naismith\'s rule)\n\n
+
Auto-split recordings after gap
Start new segment after gap of 6 min, new track after gap of 2 h, or new file after a longer gap if the date has changed.
Contour line density
@@ -687,14 +689,14 @@
Record
No data
+ \u2022 Tappable icons on the map\n\n
+ \u2022 Powerful POI filter search: Search, e.g. restaurants by cuisine, or campgrounds with specific facilities\n\n
+ \u2022 New Topo Map style for cyclists and hikers\n\n
+ \u2022 Enhanced trip recording\n\n
+ \u2022 Improved navigation notifications (Android Wear)\n\n
+ \u2022 Many other improvements and bug fixes\n\n
+ and more…
+
Contour lines color scheme
Logging minimum speed
Filter: No logging of points below this speed.
@@ -763,14 +765,14 @@
Remove selected items from \'History\'?
Show %1$s on the map
+ \u2022 New very powerful free text search\n\n
+ \u2022 Car audio system / speaker phone integration via Bluetooth\n\n
+ \u2022 Improved route guidance, voice prompting, and turn lane indication\n\n
+ \u2022 Improved transport layer with route rendering\n\n
+ \u2022 Added more locales and now support regional locales\n\n
+ \u2022 Many other improvements and bug fixes\n\n
+ and more…
+
Search %1$s away
shared via OsmAnd
Categories
@@ -832,16 +834,16 @@
No waypoints found
An anonymous user cannot:\n- Create groups;\n- Sync groups and devices with the server;\n- Manage groups and devices in a personal dashboard on the website.
Report
-
+
The app is now allowed to write to external storage, but needs to be started again to do so.
+ \u2022 OSM Live. Support map contributors and developers and get hourly map updates. \n\n
+ \u2022 Map markers. A new way to quickly select places on the map.\n\n
+ \u2022 More detailed OSM maps with country specific road shields and lots of new map features.\n\n
+ \u2022 Improved Look and Feel of Route preparation. \n\n
+ \u2022 Many improvements in the map context menu such as contextual address lookup.\n\n
+ and more…
+
Move ↑
Move ↓
Finish navigation
@@ -965,16 +967,16 @@
Show on start
Copied to clipboard
+ \u2022 New context-sensitive UI for tapping locations on the map and on other screens\n\n
+ \u2022 Map screen is now launched directly unless \'Show dashboard on app start\' is selected\n\n
+ \u2022 Configure which and how cards are displayed on the dashboard\n\n
+ \u2022 Bypass the dashboard if you like menu-based app control\n\n
+ \u2022 To download maps, regions can be directly selected by tapping on the world map\n\n
+ \u2022 POI Search now supports more specific queries\n\n
+ \u2022 Improved POI and OSM editing functionality\n\n
+ \u2022 Map data download structure and interface reworked\n\n
+ and more…
+
Save offline
Modified OSM POI
Deleted OSM POI
diff --git a/OsmAnd/res/xml/settings_pref.xml b/OsmAnd/res/xml/settings_pref.xml
index 6792b5b218..8f9e0c2fcc 100644
--- a/OsmAnd/res/xml/settings_pref.xml
+++ b/OsmAnd/res/xml/settings_pref.xml
@@ -1,6 +1,7 @@
+
diff --git a/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java b/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java
index cc0c57a2c1..db7df49a1c 100644
--- a/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java
+++ b/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java
@@ -14,6 +14,7 @@ import net.osmand.plus.OsmandPlugin;
import net.osmand.plus.R;
import net.osmand.plus.Version;
import net.osmand.plus.liveupdates.OsmLiveActivity;
+import net.osmand.plus.profiles.SettingsProfileActivity;
public class SettingsActivity extends SettingsBaseActivity {
@@ -28,6 +29,7 @@ public class SettingsActivity extends SettingsBaseActivity {
private Preference general;
private Preference routing;
private Preference subscription;
+ private Preference profiles;
@Override
@@ -40,6 +42,8 @@ public class SettingsActivity extends SettingsBaseActivity {
general.setOnPreferenceClickListener(this);
routing = (Preference) screen.findPreference("routing_settings");
routing.setOnPreferenceClickListener(this);
+ profiles = (Preference) screen.findPreference("application_profiles");
+ profiles.setOnPreferenceClickListener(this);
subscription = (Preference) screen.findPreference("subscription_settings");
subscription.setOnPreferenceClickListener(this);
@@ -88,6 +92,9 @@ public class SettingsActivity extends SettingsBaseActivity {
if (preference == general) {
startActivity(new Intent(this, SettingsGeneralActivity.class));
return true;
+ } else if (preference == profiles){
+ startActivity(new Intent(this, SettingsProfileActivity.class));
+ return true;
} else if (preference == routing) {
startActivity(new Intent(this, SettingsNavigationActivity.class));
return true;
diff --git a/OsmAnd/src/net/osmand/plus/profiles/ProfileMenuAdapter.java b/OsmAnd/src/net/osmand/plus/profiles/ProfileMenuAdapter.java
new file mode 100644
index 0000000000..9a1a3c5705
--- /dev/null
+++ b/OsmAnd/src/net/osmand/plus/profiles/ProfileMenuAdapter.java
@@ -0,0 +1,87 @@
+package net.osmand.plus.profiles;
+
+import android.graphics.drawable.Drawable;
+import android.support.annotation.NonNull;
+import android.support.v7.widget.RecyclerView;
+import android.support.v7.widget.SwitchCompat;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.View.OnClickListener;
+import android.view.ViewGroup;
+import android.widget.ImageView;
+import android.widget.TextView;
+import java.util.List;
+import net.osmand.plus.OsmandApplication;
+import net.osmand.plus.R;
+import net.osmand.plus.profiles.ProfileMenuAdapter.ProfileViewHolder;
+import net.osmand.plus.profiles.SettingsProfileActivity.ProfileItem;
+
+public class ProfileMenuAdapter extends RecyclerView.Adapter {
+
+ private List items;
+ OsmandApplication app;
+
+ public ProfileMenuAdapter(List items, OsmandApplication app) {
+ this.items = items;
+ this.app = app;
+ }
+
+ public List getItems() {
+ return items;
+ }
+
+ public void addItem(ProfileItem profileItem) {
+ items.add(profileItem);
+ notifyDataSetChanged();
+ }
+
+ @NonNull
+ @Override
+ public ProfileViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
+ View itemView = LayoutInflater.from(parent.getContext())
+ .inflate(R.layout.profile_list_item, parent, false);
+ return new ProfileViewHolder(itemView);
+ }
+
+ @Override
+ public void onBindViewHolder(@NonNull ProfileViewHolder holder, int position) {
+ ProfileItem item = items.get(position);
+ holder.title.setText(item.getTitle());
+ holder.descr.setText(item.getDescr());
+ Drawable drawable = app.getUIUtilities().getThemedIcon(item.getIconRes());
+ holder.icon.setImageDrawable(drawable);
+ holder.aSwitch.setChecked(item.getState());
+ holder.aSwitch.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ //todo change profile state;
+ }
+ });
+ holder.profileOptions.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ //todo open profile settings;
+ }
+ });
+ }
+
+ @Override
+ public int getItemCount() {
+ return items.size();
+ }
+
+ class ProfileViewHolder extends RecyclerView.ViewHolder {
+ TextView title, descr;
+ SwitchCompat aSwitch;
+ ImageView icon, profileOptions;
+
+ ProfileViewHolder(View itemView) {
+ super(itemView);
+ title = itemView.findViewById(R.id.profile_title);
+ descr = itemView.findViewById(R.id.profile_descr);
+ aSwitch = itemView.findViewById(R.id.profile_switch);
+ icon = itemView.findViewById(R.id.profile_icon);
+ profileOptions = itemView.findViewById(R.id.profile_settings);
+ }
+ }
+}
diff --git a/OsmAnd/src/net/osmand/plus/profiles/SettingsProfileActivity.java b/OsmAnd/src/net/osmand/plus/profiles/SettingsProfileActivity.java
new file mode 100644
index 0000000000..0ed2c31532
--- /dev/null
+++ b/OsmAnd/src/net/osmand/plus/profiles/SettingsProfileActivity.java
@@ -0,0 +1,90 @@
+package net.osmand.plus.profiles;
+
+import android.os.Bundle;
+import android.view.MenuItem;
+import net.osmand.plus.OsmandApplication;
+import net.osmand.plus.R;
+import net.osmand.plus.activities.OsmandActionBarActivity;
+
+public class SettingsProfileActivity extends OsmandActionBarActivity {
+
+ private OsmandApplication app;
+
+
+
+ @Override
+ public void onCreate(Bundle savedInstanceState) {
+ app = getMyApplication();
+ app.applyTheme(this);
+ super.onCreate(savedInstanceState);
+ setContentView(R.layout.single_fragment_layout);
+ if (savedInstanceState == null) {
+ SettingsProfileFragment profileFragment = new SettingsProfileFragment();
+ profileFragment.setArguments(getIntent().getExtras());
+ getSupportFragmentManager().beginTransaction().add(android.R.id.content, profileFragment).commit();
+ }
+ }
+
+ @Override
+ public boolean onOptionsItemSelected(MenuItem item) {
+ int itemId = item.getItemId();
+ switch (itemId) {
+ case android.R.id.home:
+ finish();
+ return true;
+
+ }
+ return false;
+ }
+
+ @Override
+ protected void onResume() {
+ super.onResume();
+ }
+
+ public class ProfileItem {
+ private int iconRes;
+ private String title;
+ private String descr;
+ private boolean state;
+
+ public ProfileItem(int iconRes, String title, String descr, boolean state) {
+ this.iconRes = iconRes;
+ this.title = title;
+ this.descr = descr;
+ this.state = state;
+ }
+
+ public int getIconRes() {
+ return iconRes;
+ }
+
+ public void setIconRes(int iconRes) {
+ this.iconRes = iconRes;
+ }
+
+ public String getTitle() {
+ return title;
+ }
+
+ public void setTitle(String title) {
+ this.title = title;
+ }
+
+ public String getDescr() {
+ return descr;
+ }
+
+ public void setDescr(String descr) {
+ this.descr = descr;
+ }
+
+ public boolean getState() {
+ return state;
+ }
+
+ public void setState(boolean state) {
+ this.state = state;
+ }
+ }
+}
diff --git a/OsmAnd/src/net/osmand/plus/profiles/SettingsProfileFragment.java b/OsmAnd/src/net/osmand/plus/profiles/SettingsProfileFragment.java
new file mode 100644
index 0000000000..65f8dbfe8c
--- /dev/null
+++ b/OsmAnd/src/net/osmand/plus/profiles/SettingsProfileFragment.java
@@ -0,0 +1,42 @@
+package net.osmand.plus.profiles;
+
+import android.os.Bundle;
+import android.support.annotation.NonNull;
+import android.support.annotation.Nullable;
+import android.support.v7.widget.AppCompatButton;
+import android.support.v7.widget.RecyclerView;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.View.OnClickListener;
+import android.view.ViewGroup;
+import net.osmand.PlatformUtil;
+import net.osmand.plus.R;
+import net.osmand.plus.base.BaseOsmAndFragment;
+import org.apache.commons.logging.Log;
+
+public class SettingsProfileFragment extends BaseOsmAndFragment {
+
+ private static final Log LOG = PlatformUtil.getLog(SettingsProfileFragment.class);
+
+ private ProfileMenuAdapter adapter;
+ private RecyclerView recyclerView;
+ private AppCompatButton btn;
+
+ @Nullable
+ @Override
+ public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,
+ @Nullable Bundle savedInstanceState) {
+ View view = inflater.inflate(R.layout.profiles_list_fragment, container, false);
+
+ recyclerView = view.findViewById(R.id.profiles_list);
+ btn = view.findViewById(R.id.add_profile_btn);
+ btn.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ //todo add new profile;
+ }
+ });
+
+ return view;
+ }
+}