【发布时间】:2015-01-20 09:42:04
【问题描述】:
我们的应用在华为8510上是这样的,安卓版本是2.3.5。 此屏幕截图来自我们的客户。我们在应用程序上禁用了屏幕截图,因此我们的客户使用另一部手机进行屏幕截图。
这怎么可能?
这是我认为没有问题的布局代码。
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
android:layout_width="0px"
android:layout_height="0px"
android:focusable="true"
android:focusableInTouchMode="true" />
<com.asdasd.asdasd.controls.CMScrollView
android:id="@+id/scvAgreement"
style="@style/pm_ContentStyle"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:fadingEdge="none"
android:paddingLeft="0dp"
android:paddingRight="0dp">
<TextView
android:id="@+id/tvAgreement"
style="@style/pm_TextStyle"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="@dimen/pm_content_padding_left"
android:layout_marginRight="@dimen/pm_content_padding_right"
android:gravity="center"
android:text=""
android:typeface="monospace" />
</com.asdasd.asdasd.controls.CMScrollView>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="0"
android:orientation="horizontal">
<Button
style="@style/pm_ButtonStyle_Standart"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="@drawable/selector_btn_black"
android:gravity="center"
android:onClick="onBtnNegativeClicked"
android:text="@string/pgPrivacy_btnNotAccept"
android:textSize="@dimen/pm_middle_text_size"
android:singleLine="false"/>
<Button
android:id="@+id/btnSendAgreement"
style="@style/pm_ButtonStyle_Standart"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/pm_button_margin_left"
android:layout_weight="1"
android:background="@drawable/selector_btn_black"
android:enabled="false"
android:gravity="center"
android:onClick="onBtnSendAgreement"
android:text="@string/pgPrivacy_btnSendAgreement"
android:textSize="@dimen/pm_middle_text_size"
android:singleLine="false"/>
<Button
android:id="@+id/btnPositive"
style="@style/pm_ButtonStyle_Standart"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/pm_button_margin_left"
android:layout_weight="1"
android:background="@drawable/selector_btn_orange"
android:enabled="false"
android:gravity="center"
android:onClick="onBtnPositiveClicked"
android:text="@string/pgPrivacy_btnAccept"
android:textSize="@dimen/pm_middle_text_size"
android:singleLine="false"/>
</LinearLayout>
还有,我们的自定义列表视图
public class CMScrollView extends ScrollView {
public static final String LOG_TAG = "com.asdasd.asdasd.controls.CMScrollView";
private OnScrollViewReachedToEnd onScrollViewReachedToEnd;
public CMScrollView(Context context, AttributeSet st) {
super(context, st);
}
public OnScrollViewReachedToEnd getOnScrollViewReachedToEnd() {
return onScrollViewReachedToEnd;
}
public void setOnScrollViewReachedToEnd(OnScrollViewReachedToEnd onScrollViewReachedToEnd) {
this.onScrollViewReachedToEnd = onScrollViewReachedToEnd;
}
@Override
protected void onScrollChanged(int l, int t, int oldl, int oldt) {
View view = (View) getChildAt(getChildCount() - 1);
int diff = (view.getBottom() - (getHeight() + getScrollY() + view.getTop()));// Calculate the scrolldiff
if (diff == 0) { // if diff is zero, then the bottom has been reached
if (ApplicationController.DEBUGMODE)
Log.d(CMScrollView.LOG_TAG, "MyScrollView: Bottom has been reached");
if (onScrollViewReachedToEnd != null) {
onScrollViewReachedToEnd.onReachedToEnd(this);
}
}
super.onScrollChanged(l, t, oldl, oldt);
}
public interface OnScrollViewReachedToEnd {
void onReachedToEnd(IngScrollView scrollView);
}}
在 AndroidManifest GL 版本上:
<uses-feature
android:glEsVersion="0x00020000"
android:required="true" />
【问题讨论】:
-
任何人都需要更多信息才能尝试帮助您。 Android 版本将有助于开始。
-
另外,我不知道应该向您提供哪些信息。我有任何想法,@Peter。
-
我们至少需要查看消息来源才能对此发表任何看法。您是使用标准视图创建 GUI,还是使用 RenderScript 或某种 OpenGL 库?
-
是的,我们使用的是标准控件,@SubliemeSiem
-
这看起来像是硬件问题,而不是软件问题。如果仅由一位用户检测到,请耐心等待,如果有多个用户。
标签: android android-layout android-activity android-fragments