Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
com.ccwangluo.accelerator
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sheteng
com.ccwangluo.accelerator
Commits
ff0cd960
Commit
ff0cd960
authored
Jul 13, 2018
by
Mygod
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix more crashes
parent
ed0265cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
mobile/src/main/java/com/github/shadowsocks/widget/HackyTextView.kt
.../main/java/com/github/shadowsocks/widget/HackyTextView.kt
+8
-0
No files found.
mobile/src/main/java/com/github/shadowsocks/widget/HackyTextView.kt
View file @
ff0cd960
...
...
@@ -21,6 +21,7 @@
package
com.github.shadowsocks.widget
import
android.content.Context
import
android.graphics.Rect
import
android.support.v7.widget.AppCompatTextView
import
android.util.AttributeSet
import
android.view.MotionEvent
...
...
@@ -28,6 +29,13 @@ import com.crashlytics.android.Crashlytics
class
HackyTextView
@JvmOverloads
constructor
(
context
:
Context
,
attrs
:
AttributeSet
?
=
null
,
defStyleAttr
:
Int
=
0
)
:
AppCompatTextView
(
context
,
attrs
,
defStyleAttr
)
{
override
fun
onFocusChanged
(
focused
:
Boolean
,
direction
:
Int
,
previouslyFocusedRect
:
Rect
?)
=
try
{
super
.
onFocusChanged
(
focused
,
direction
,
previouslyFocusedRect
)
}
catch
(
e
:
IndexOutOfBoundsException
)
{
e
.
printStackTrace
()
Crashlytics
.
logException
(
e
)
}
override
fun
onTouchEvent
(
event
:
MotionEvent
?)
=
try
{
super
.
onTouchEvent
(
event
)
}
catch
(
e
:
IndexOutOfBoundsException
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment