Obsolete
Status Update
Comments
ig...@udachi.net <ig...@udachi.net> #2
Thanks for the post,
To investigate further, can you share more details on your use case where you are using the Glide? Kindly also note that Glide is "An image loading and caching library for Android focused on smooth scrolling", this may have implementations against the Terms of Service of Google Maps Platform[1] under "3.2.4(b) No Caching. Customer will not cache Google Maps Content except as expressly permitted under the Maps Service Specific Terms.".
Kindly review the ToS of Google Maps Platform, once confirmed that your use case is compliant, we will be glad to proceed with the investigation.
[1]https://cloud.google.com/maps-platform/terms/#3-license
To investigate further, can you share more details on your use case where you are using the Glide? Kindly also note that Glide is "An image loading and caching library for Android focused on smooth scrolling", this may have implementations against the Terms of Service of Google Maps Platform[1] under "3.2.4(b) No Caching. Customer will not cache Google Maps Content except as expressly permitted under the Maps Service Specific Terms.".
Kindly review the ToS of Google Maps Platform, once confirmed that your use case is compliant, we will be glad to proceed with the investigation.
[1]
ro...@android.com <ro...@android.com>
ro...@google.com <ro...@google.com>
cl...@google.com <cl...@google.com>
si...@google.com <si...@google.com>
sa...@google.com <sa...@google.com> #3
Thanks for your reply. I'm using Glide to load content that is not related to Google Maps in any way. The crash happens when Maps SDK 3.0.0 Beta and a specific configuration of Glide co-exists in the same app, even if their usages are completely unrelated.
Description
Code to reproduce:
<RelativeLayout xmlns:android="
xmlns:tools="
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity" >
<TextView
android:id="@+id/textView1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Line 0\nLine 1\nLine 2\nLine 3\nLine 4"
android:textSize="10sp" />
<Button
android:id="@+id/button1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/textView1"
android:layout_alignParentBottom="true"
android:onClick="onBtnClick"
android:text="Button" />
</RelativeLayout>
public class MainActivity extends Activity {
Layout layout;
TextView tv;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
tv = (TextView) findViewById(R.id.textView1);
}
public void onBtnClick(View view) {
float density = getResources().getDisplayMetrics().density;
layout = tv.getLayout();
int line_top = 0;
int previous_line = 0;
for (int i = 0; i < layout.getLineCount(); i++) {
line_top = layout.getLineTop(i);
Log.d("bug", "Text Size: "
+ (int) (tv.getTextSize() / density + 0.5f)
+ " line_top: " + line_top + " curr - prev: "
+ (line_top - previous_line));
previous_line = line_top;
}
}
}
Set 'bug' as Log filter..
Nexus7 emulator,
TextView text size 10sp:
Text Size: 10 line_top: 0 curr - prev: 0
Text Size: 10 line_top: 17 curr - prev: 17
Text Size: 10 line_top: 32 curr - prev: 15
Text Size: 10 line_top: 47 curr - prev: 15
Text Size: 10 line_top: 62 curr - prev: 15
*** The first's line height is 17, the rest lines are 15
*** 17 - 15 = 2 => 0.2 of the text size.
TextView text size 20sp:
Text Size: 20 line_top: 0 curr - prev: 0
Text Size: 20 line_top: 36 curr - prev: 36
Text Size: 20 line_top: 68 curr - prev: 32
Text Size: 20 line_top: 100 curr - prev: 32
Text Size: 20 line_top: 132 curr - prev: 32
*** Same with text size 20.. 36 - 32 = 4 => 0.2 of the text size.
TextView text size 30sp:
Text Size: 30 line_top: 0 curr - prev: 0
Text Size: 30 line_top: 53 curr - prev: 53
Text Size: 30 line_top: 100 curr - prev: 47
Text Size: 30 line_top: 147 curr - prev: 47
Text Size: 30 line_top: 194 curr - prev: 47
*** Same with text size 30.. 53 - 47 = 6 => 0.2 of the text size.
Also done with Nexus S emulator and SG4 real device. Same 0.2 scale error.