Update small issues

This commit is contained in:
Victor Shcherb 2018-04-03 20:42:56 +02:00
parent 2825cfc38c
commit e9a8819a8c
11 changed files with 11 additions and 265 deletions

View file

@ -12,7 +12,6 @@
android:layout_height="wrap_content"> android:layout_height="wrap_content">
<LinearLayout <LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:orientation="vertical"> android:orientation="vertical">

View file

@ -1,12 +1,11 @@
<FrameLayout <FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<ExpandableListView <ExpandableListView
android:id="@android:id/list" android:id="@android:id/list"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:divider="@null" android:divider="@null"

View file

@ -1,10 +1,11 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
xmlns:osmand="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:orientation="vertical"> android:orientation="vertical">
<ImageView xmlns:android="http://schemas.android.com/apk/res/android" <ImageView
android:id="@+id/shadow_on_map" android:id="@+id/shadow_on_map"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
@ -131,7 +132,7 @@
</LinearLayout> </LinearLayout>
</RelativeLayout> </RelativeLayout>
<LinearLayout xmlns:osmand="http://schemas.android.com/apk/res-auto" <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:clickable="false" android:clickable="false"

View file

@ -10,7 +10,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content"/> android:layout_height="wrap_content"/>
<TextView xmlns:android="http://schemas.android.com/apk/res/android" <TextView
android:id="@+id/tab_title" android:id="@+id/tab_title"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent"

View file

@ -121,7 +121,6 @@
<!--android:src="@drawable/bg_shadow_list_top"/>--> <!--android:src="@drawable/bg_shadow_list_top"/>-->
<LinearLayout <LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="?attr/bg_color" android:background="?attr/bg_color"

View file

@ -1,20 +0,0 @@
<android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/drawer_layout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<!-- The main content view -->
<FrameLayout
android:id="@+id/content_frame"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<!-- The navigation drawer -->
<ListView
android:id="@+id/left_drawer"
android:layout_width="240dp"
android:layout_height="match_parent"
android:layout_gravity="start"
android:choiceMode="singleChoice"
android:divider="@drawable/divider"
android:dividerHeight="1px"
android:background="@color/color_white" />
</android.support.v4.widget.DrawerLayout>

View file

@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:paddingBottom="8dp"
android:paddingTop="8dp">
<ImageView
android:id="@+id/Icon"
android:layout_width="32dp"
android:layout_height="32dp"
android:layout_marginLeft="12dp"
android:layout_marginRight="12dp" />
<TextView
android:id="@+id/Text"
android:layout_width="match_parent"
android:layout_gravity="center_vertical"
android:gravity="center_vertical"
android:textSize="@dimen/default_list_text_size"
android:layout_height="wrap_content"
android:ellipsize="end"
android:maxLines="1" />
</LinearLayout>

View file

@ -1,77 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/sherpafy_tour_row">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="15dp"
android:layout_marginLeft="14dp"
android:layout_marginRight="14dp"
android:layout_marginTop="15dp"
android:id="@+id/AreaPreview"
android:background="@drawable/tour_bg"
android:orientation="vertical">
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageView
android:layout_marginLeft="1dp"
android:layout_marginRight="1dp"
android:layout_marginTop="1dp"
android:id="@+id/TourImage"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"></ImageView>
<TextView
android:id="@+id/TourName"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginLeft="10dp"
android:layout_marginRight="6dp"
android:background="@color/shadow_color"
android:ellipsize="end"
android:maxLines="1"
android:textColor="@color/color_white"
android:textSize="@dimen/default_list_text_size_large" />
</FrameLayout>
<TextView
android:id="@+id/TourDescription"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="5dp"
android:layout_marginTop="5dp"
android:layout_weight="1"
android:ellipsize="end"
android:maxLines="3"
android:textSize="@dimen/default_list_text_size"/>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="14dp"
android:layout_marginRight="14dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="3dp"
android:orientation="vertical">
<TextView
android:id="@+id/MoreInformation"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textSize="@dimen/default_desc_text_size"
android:focusable="false" />
</LinearLayout>
</LinearLayout>
</FrameLayout>

View file

@ -1,75 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<net.osmand.plus.views.OsmAndMapSurfaceView
android:id="@+id/MapView"
android:layout_width="fill_parent"
android:layout_height="300dp"
android:contentDescription="@string/shared_string_map"
android:visibility="gone" />
<ScrollView
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@color/color_white"
android:orientation="vertical">
<ImageView
android:id="@+id/Icon"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:scaleType="centerCrop" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="5dp"
android:orientation="horizontal">
<TextView
android:id="@+id/HeaderText"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center_vertical"
android:textSize="@dimen/default_list_text_size_large" />
<TextView
android:id="@+id/AdditionalText"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_marginLeft="7dp"
android:textColor="@color/sherpafy_add_text"
android:textSize="@dimen/default_list_text_size" />
</LinearLayout>
<TextView
android:id="@+id/Text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="8dp"
android:singleLine="false"
android:textColor="@color/sherpafy_add_text"
android:textSize="@dimen/default_list_text_size" />
<WebView
android:id="@+id/Description"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="8dp" />
</LinearLayout>
</ScrollView>
</LinearLayout>

View file

@ -1,56 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingBottom="8dp"
android:paddingTop="8dp"
android:orientation="horizontal">
<FrameLayout
android:layout_width="48dp"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp">
<ImageView
android:id="@+id/Icon"
android:layout_width="48dp"
android:layout_height="48dp" />
</FrameLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical">
<TextView
android:id="@+id/HeaderText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ellipsize="end"
android:gravity="center_vertical"
android:maxLines="1"
android:textSize="@dimen/default_list_text_size_large" />
<TextView
android:id="@+id/Text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ellipsize="end"
android:gravity="center_vertical"
android:maxLines="1"
android:textSize="@dimen/default_desc_text_size"/>
</LinearLayout>
<TextView
android:id="@+id/AdditionalText"
android:layout_width="40dp"
android:layout_height="fill_parent"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:layout_gravity="center_vertical"
android:textColor="@color/sherpafy_add_text"
android:textSize="@dimen/default_desc_text_size"/>
</LinearLayout>

View file

@ -14,10 +14,10 @@ import android.widget.ArrayAdapter;
import android.widget.Filterable; import android.widget.Filterable;
import android.widget.TextView; import android.widget.TextView;
import android.widget.Toast; import android.widget.Toast;
import net.osmand.AndroidUtils; import net.osmand.AndroidUtils;
import net.osmand.osm.io.NetworkUtils; import net.osmand.osm.io.NetworkUtils;
import net.osmand.plus.R; import net.osmand.plus.R;
import net.osmand.plus.Version;
import org.xmlpull.v1.XmlPullParser; import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserFactory; import org.xmlpull.v1.XmlPullParserFactory;
@ -41,8 +41,8 @@ public class ContributionVersionActivity extends OsmandListActivity {
private static final int INSTALL_BUILD = 2; private static final int INSTALL_BUILD = 2;
private static final int ACTIVITY_TO_INSTALL = 23; private static final int ACTIVITY_TO_INSTALL = 23;
private static final String URL_TO_RETRIEVE_BUILDS = "http://download.osmand.net/builds.php"; private static final String URL_TO_RETRIEVE_BUILDS = "https://download.osmand.net/builds.php";
private static final String URL_GET_BUILD = "http://download.osmand.net/"; private static final String URL_GET_BUILD = "https://download.osmand.net/";
private ProgressDialog progressDlg; private ProgressDialog progressDlg;
private Date currentInstalledDate; private Date currentInstalledDate;
@ -158,7 +158,9 @@ public class ContributionVersionActivity extends OsmandListActivity {
} }
} }
OsmAndBuild build = new OsmAndBuild(path, size, d, tag); OsmAndBuild build = new OsmAndBuild(path, size, d, tag);
downloadedBuilds.add(build); if(!Version.isFreeVersion(getMyApplication()) || path.contains("default")) {
downloadedBuilds.add(build);
}
} }
} }
} }