Skip to content

Commit

Permalink
fix all select bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jaeger committed Sep 12, 2016
1 parent e789cc1 commit 7886ce5
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ public void onClick(View v) {
public void onClick(View v) {
hideSelect();
selectText(0, mTextView.getText().length() - 1);
isHide = false;
showCursor(mStartHandle);
showCursor(mEndHandle);
mOperateWindow.show();
Expand Down
29 changes: 23 additions & 6 deletions sample/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,30 @@
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="@+id/tv_test"

<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:bufferType="spannable"
android:lineSpacingExtra="3dp"
android:text="@string/long_text"
android:textSize="16sp"/>
android:orientation="vertical">
<TextView
android:id="@+id/tv_test"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:bufferType="spannable"
android:lineSpacingExtra="3dp"
android:text="@string/long_text"
android:textSize="16sp"/>

<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:bufferType="spannable"
android:lineSpacingExtra="3dp"
android:text="@string/long_text"
android:textSize="16sp"/>
</LinearLayout>

</ScrollView>

<Button
Expand All @@ -25,4 +41,5 @@
android:layout_height="wrap_content"
android:visibility="gone"/>


</LinearLayout>

0 comments on commit 7886ce5

Please sign in to comment.