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
195e2afb
Commit
195e2afb
authored
Jan 15, 2018
by
Mygod
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix keyboard navigations
parent
3dbc5f41
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
2 deletions
+12
-2
mobile/src/main/java/com/github/shadowsocks/preference/BottomSheetPreferenceDialogFragment.kt
...owsocks/preference/BottomSheetPreferenceDialogFragment.kt
+3
-0
mobile/src/main/res/drawable-v21/background_selectable.xml
mobile/src/main/res/drawable-v21/background_selectable.xml
+3
-2
mobile/src/main/res/drawable/background_selectable.xml
mobile/src/main/res/drawable/background_selectable.xml
+3
-0
mobile/src/main/res/xml/pref_profile.xml
mobile/src/main/res/xml/pref_profile.xml
+2
-0
plugin/src/main/res/layout/toolbar_light_dark.xml
plugin/src/main/res/layout/toolbar_light_dark.xml
+1
-0
No files found.
mobile/src/main/java/com/github/shadowsocks/preference/BottomSheetPreferenceDialogFragment.kt
View file @
195e2afb
...
@@ -29,6 +29,7 @@ import android.os.Bundle
...
@@ -29,6 +29,7 @@ import android.os.Bundle
import
android.provider.Settings
import
android.provider.Settings
import
android.support.design.widget.BottomSheetDialog
import
android.support.design.widget.BottomSheetDialog
import
android.support.v7.preference.PreferenceDialogFragmentCompat
import
android.support.v7.preference.PreferenceDialogFragmentCompat
import
android.support.v7.widget.DefaultItemAnimator
import
android.support.v7.widget.LinearLayoutManager
import
android.support.v7.widget.LinearLayoutManager
import
android.support.v7.widget.RecyclerView
import
android.support.v7.widget.RecyclerView
import
android.view.LayoutInflater
import
android.view.LayoutInflater
...
@@ -107,10 +108,12 @@ class BottomSheetPreferenceDialogFragment : PreferenceDialogFragmentCompat() {
...
@@ -107,10 +108,12 @@ class BottomSheetPreferenceDialogFragment : PreferenceDialogFragmentCompat() {
recycler
.
setPadding
(
0
,
padding
,
0
,
padding
)
recycler
.
setPadding
(
0
,
padding
,
0
,
padding
)
recycler
.
setHasFixedSize
(
true
)
recycler
.
setHasFixedSize
(
true
)
recycler
.
layoutManager
=
LinearLayoutManager
(
activity
)
recycler
.
layoutManager
=
LinearLayoutManager
(
activity
)
recycler
.
itemAnimator
=
DefaultItemAnimator
()
recycler
.
adapter
=
IconListAdapter
(
dialog
)
recycler
.
adapter
=
IconListAdapter
(
dialog
)
recycler
.
layoutParams
=
ViewGroup
.
LayoutParams
(
recycler
.
layoutParams
=
ViewGroup
.
LayoutParams
(
ViewGroup
.
LayoutParams
.
MATCH_PARENT
,
ViewGroup
.
LayoutParams
.
WRAP_CONTENT
)
ViewGroup
.
LayoutParams
.
MATCH_PARENT
,
ViewGroup
.
LayoutParams
.
WRAP_CONTENT
)
dialog
.
setContentView
(
recycler
)
dialog
.
setContentView
(
recycler
)
dialog
.
findViewById
<
View
>(
R
.
id
.
touch_outside
)
!!
.
isFocusable
=
false
return
dialog
return
dialog
}
}
...
...
mobile/src/main/res/drawable-v21/background_selectable.xml
View file @
195e2afb
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<
ripple
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:color=
"?android:colorControlHighlight
"
>
<
layer-list
xmlns:android=
"http://schemas.android.com/apk/res/android
"
>
<item>
<item>
<selector
android:enterFadeDuration=
"@android:integer/config_mediumAnimTime"
<selector
android:enterFadeDuration=
"@android:integer/config_mediumAnimTime"
android:exitFadeDuration=
"@android:integer/config_mediumAnimTime"
>
android:exitFadeDuration=
"@android:integer/config_mediumAnimTime"
>
...
@@ -8,4 +8,5 @@
...
@@ -8,4 +8,5 @@
</item>
</item>
</selector>
</selector>
</item>
</item>
</ripple>
<item
android:drawable=
"?android:attr/selectableItemBackground"
/>
</layer-list>
mobile/src/main/res/drawable/background_selectable.xml
View file @
195e2afb
...
@@ -5,4 +5,7 @@
...
@@ -5,4 +5,7 @@
<item
android:state_selected=
"true"
>
<item
android:state_selected=
"true"
>
<color
android:color=
"@color/material_primary_100"
/>
<color
android:color=
"@color/material_primary_100"
/>
</item>
</item>
<item
android:state_pressed=
"true"
>
<color
android:color=
"#12000000"
/>
</item>
</selector>
</selector>
mobile/src/main/res/xml/pref_profile.xml
View file @
195e2afb
...
@@ -13,6 +13,7 @@
...
@@ -13,6 +13,7 @@
<AutoSummaryEditTextPreference
<AutoSummaryEditTextPreference
android:key=
"proxy"
android:key=
"proxy"
app:pref_summaryHasText=
"%s"
app:pref_summaryHasText=
"%s"
android:singleLine=
"true"
android:title=
"@string/proxy"
/>
android:title=
"@string/proxy"
/>
<AutoSummaryEditTextPreference
<AutoSummaryEditTextPreference
android:key=
"remotePortNum"
android:key=
"remotePortNum"
...
@@ -25,6 +26,7 @@
...
@@ -25,6 +26,7 @@
app:pref_summaryPasswordSubstituteLength=
"0"
app:pref_summaryPasswordSubstituteLength=
"0"
android:key=
"sitekey"
android:key=
"sitekey"
app:pref_summaryHasText=
"%s"
app:pref_summaryHasText=
"%s"
android:singleLine=
"true"
android:title=
"@string/sitekey"
/>
android:title=
"@string/sitekey"
/>
<SimpleMenuPreference
<SimpleMenuPreference
android:key=
"encMethod"
android:key=
"encMethod"
...
...
plugin/src/main/res/layout/toolbar_light_dark.xml
View file @
195e2afb
...
@@ -6,6 +6,7 @@
...
@@ -6,6 +6,7 @@
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:background=
"?attr/colorPrimary"
android:background=
"?attr/colorPrimary"
android:elevation=
"4dp"
android:elevation=
"4dp"
android:touchscreenBlocksFocus=
"false"
android:theme=
"@style/ThemeOverlay.AppCompat.Dark.ActionBar"
android:theme=
"@style/ThemeOverlay.AppCompat.Dark.ActionBar"
app:popupTheme=
"@style/ThemeOverlay.AppCompat.Light"
app:popupTheme=
"@style/ThemeOverlay.AppCompat.Light"
android:id=
"@+id/toolbar"
/>
android:id=
"@+id/toolbar"
/>
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