Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
YGOMobile
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
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
fallenstardust
YGOMobile
Commits
ec82fb22
Commit
ec82fb22
authored
Jul 26, 2022
by
fallenstardust
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化搜索关键词被输入法界面遮挡
parent
7ebe0de5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
213 additions
and
212 deletions
+213
-212
mobile/src/main/java/cn/garymb/ygomobile/ui/home/HomeFragment.java
...c/main/java/cn/garymb/ygomobile/ui/home/HomeFragment.java
+1
-5
mobile/src/main/res/layout/nav_card_search.xml
mobile/src/main/res/layout/nav_card_search.xml
+212
-207
No files found.
mobile/src/main/java/cn/garymb/ygomobile/ui/home/HomeFragment.java
View file @
ec82fb22
...
...
@@ -183,10 +183,6 @@ public class HomeFragment extends BaseFragemnt implements OnDuelAssistantListene
return true;
}
});*/
// cv_reset_res = view.findViewById(R.id.action_reset_game_res);
// cv_reset_res.setOnClickListener(this);
// cv_join_QQ = view.findViewById(R.id.action_join_qq_group);
// cv_join_QQ.setOnClickListener(this);
cv_donation
=
view
.
findViewById
(
R
.
id
.
nav_webpage
);
cv_donation
.
setOnClickListener
(
this
);
cv_help
=
view
.
findViewById
(
R
.
id
.
action_help
);
...
...
@@ -204,7 +200,7 @@ public class HomeFragment extends BaseFragemnt implements OnDuelAssistantListene
//轮播图
public
void
initBanner
(
View
view
,
Bundle
saveBundle
)
{
xb_banner
=
view
.
findViewById
(
R
.
id
.
xb_banner
);
cv_banner
=
(
CardView
)
view
.
findViewById
(
R
.
id
.
cv_banner
);
cv_banner
=
view
.
findViewById
(
R
.
id
.
cv_banner
);
cv_banner
.
post
(()
->
{
ViewGroup
.
LayoutParams
layoutParams
=
cv_banner
.
getLayoutParams
();
layoutParams
.
width
=
cv_banner
.
getWidth
();
...
...
mobile/src/main/res/layout/nav_card_search.xml
View file @
ec82fb22
...
...
@@ -10,150 +10,44 @@
android:theme=
"@style/AppTheme.PopupOverlay.Dark"
tools:showIn=
"@layout/fragment_search"
>
<
LinearLayout
<
ScrollView
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_marginTop=
"6dp"
android:orientation=
"vertical"
>
android:layout_height=
"match_parent"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"match_parent"
android:layout_marginTop=
"6dp"
android:orientation=
"vertical"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_ot"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:textSize=
"12sp"
/>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_my_fav"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
android:background=
"@color/transparent"
android:text=
"@string/my_favorites"
android:textColor=
"@color/selector_text_color_white_gold"
android:visibility=
"visible"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/label_width_small"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_limit_list"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_limit"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
android:visibility=
"invisible"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/label_width_small"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_category"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_scale"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"invisible"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/label_width_small"
android:orientation=
"horizontal"
>
<cn.garymb.ygomobile.ui.widget.SearchableSpinner
android:id=
"@+id/sp_setcode"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
app:searchTitle=
"@string/label_set"
/>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_linkmarker"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
android:background=
"@color/transparent"
android:text=
"@string/linkmarker"
android:visibility=
"visible"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"
horizont
al"
>
android:orientation=
"
vertic
al"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_card"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
/>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_race"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"gone"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_ot"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:textSize=
"12sp"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_spell"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"gone"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_trap"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"gone"
/>
</LinearLayout>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_my_fav"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
android:background=
"@color/transparent"
android:text=
"@string/my_favorites"
android:textColor=
"@color/selector_text_color_white_gold"
android:visibility=
"visible"
/>
<LinearLayout
android:id=
"@+id/layout_monster"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
...
...
@@ -161,18 +55,19 @@
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_l
evel
"
android:id=
"@+id/sp_l
imit_list
"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_
attribute
"
android:id=
"@+id/sp_
limit
"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
android:layout_weight=
"1"
android:visibility=
"invisible"
/>
</LinearLayout>
<LinearLayout
...
...
@@ -181,110 +76,220 @@
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_
type_monster
"
android:id=
"@+id/sp_
category
"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_
type_monster2
"
android:id=
"@+id/sp_
scale
"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"invisible"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/label_width_small"
android:orientation=
"horizontal"
>
<cn.garymb.ygomobile.ui.widget.SearchableSpinner
android:id=
"@+id/sp_setcode"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
app:searchTitle=
"@string/label_set"
/>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_linkmarker"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
android:background=
"@color/transparent"
android:text=
"@string/linkmarker"
android:visibility=
"visible"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"10dp"
android:orientation=
"horizontal"
>
<com.google.android.material.textfield.TextInputLayout
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_card"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"
wrap_content
"
android:layout_weight=
"1"
>
android:layout_height=
"
@dimen/label_width_small
"
android:layout_weight=
"1"
/
>
<androidx.appcompat.widget.AppCompatEditText
android:id=
"@+id/edt_atk"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:hint=
"@string/hit_atk"
android:maxLines=
"1"
android:singleLine=
"true"
tools:text=
"100"
/>
</com.google.android.material.textfield.TextInputLayout>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_race"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"gone"
/>
<com.google.android.material.textfield.TextInputLayout
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_spell"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"gone"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_trap"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"@dimen/label_width_small"
android:layout_weight=
"1"
android:visibility=
"gone"
/>
</LinearLayout>
<LinearLayout
android:id=
"@+id/layout_monster"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/label_width_small"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_level"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_attribute"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/label_width_small"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_monster"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
<androidx.appcompat.widget.AppCompatSpinner
android:id=
"@+id/sp_type_monster2"
style=
"@style/itemSpinnerStyle"
android:layout_width=
"0dp"
android:layout_height=
"match_parent"
android:layout_weight=
"1"
/>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
>
android:layout_marginLeft=
"10dp"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatEditText
android:id=
"@+id/edt_def"
android:layout_width=
"match_parent"
<com.google.android.material.textfield.TextInputLayout
android:layout_width=
"0dp"
android:layout_height=
"wrap_content"
android:hint=
"@string/hit_def"
android:maxLines=
"1"
android:singleLine=
"true"
tools:text=
"100"
/>
</com.google.android.material.textfield.TextInputLayout>
android:layout_weight=
"1"
>
<androidx.appcompat.widget.AppCompatEditText
android:id=
"@+id/edt_atk"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:hint=
"@string/hit_atk"
android:maxLines=
"1"
android:singleLine=
"true"
tools:text=
"100"
/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:layout_width=
"0dp"
android:layout_height=
"wrap_content"
android:layout_weight=
"1"
>
<androidx.appcompat.widget.AppCompatEditText
android:id=
"@+id/edt_def"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:hint=
"@string/hit_def"
android:maxLines=
"1"
android:singleLine=
"true"
tools:text=
"100"
/>
</com.google.android.material.textfield.TextInputLayout>
</LinearLayout>
</LinearLayout>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"10dp"
android:orientation=
"horizontal"
>
<com.google.android.material.textfield.TextInputLayout
android:layout_width=
"0dp"
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_margin
Left
=
"10dp"
android:
layout_weight=
"1
"
>
android:layout_margin
Top
=
"10dp"
android:
orientation=
"horizontal
"
>
<androidx.appcompat.widget.AppCompatEditText
android:id=
"@+id/edt_word1"
android:layout_width=
"match_parent"
<com.google.android.material.textfield.TextInputLayout
android:layout_width=
"0dp"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_vertical"
android:hint=
"@string/hit_keyword1"
android:imeOptions=
"actionSearch"
android:inputType=
"textNoSuggestions"
android:maxLines=
"1"
android:singleLine=
"true"
android:textColorHint=
"@color/gold"
/>
</com.google.android.material.textfield.TextInputLayout>
android:layout_marginLeft=
"10dp"
android:layout_weight=
"1"
>
</LinearLayout>
<androidx.appcompat.widget.AppCompatEditText
android:id=
"@+id/edt_word1"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_vertical"
android:hint=
"@string/hit_keyword1"
android:imeOptions=
"actionSearch"
android:inputType=
"textNoSuggestions"
android:maxLines=
"1"
android:singleLine=
"true"
android:textColorHint=
"@color/gold"
/>
</com.google.android.material.textfield.TextInputLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_reset"
android:layout_marginLeft=
"10dp"
android:layout_marginRight=
"10dp"
android:layout_width=
"wrap_content"
android:layout_height=
"40dp"
android:layout_gravity=
"center_vertical"
android:background=
"@drawable/button_bg"
android:text=
"@string/reset"
/>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_search"
</LinearLayout>
<LinearLayout
android:layout_width=
"match_parent"
android:layout_height=
"40dp"
android:layout_marginLeft=
"20dp"
android:layout_marginRight=
"10dp"
android:layout_gravity=
"center_vertical"
android:background=
"@drawable/button_bg"
android:text=
"@string/search"
/>
android:layout_height=
"wrap_content"
android:orientation=
"horizontal"
>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_reset"
android:layout_width=
"wrap_content"
android:layout_height=
"40dp"
android:layout_gravity=
"center_vertical"
android:layout_marginLeft=
"10dp"
android:layout_marginRight=
"10dp"
android:background=
"@drawable/button_bg"
android:text=
"@string/reset"
/>
<androidx.appcompat.widget.AppCompatButton
android:id=
"@+id/btn_search"
android:layout_width=
"match_parent"
android:layout_height=
"40dp"
android:layout_gravity=
"center_vertical"
android:layout_marginLeft=
"20dp"
android:layout_marginRight=
"10dp"
android:background=
"@drawable/button_bg"
android:text=
"@string/search"
/>
</LinearLayout>
</LinearLayout>
</
LinearLayout
>
</
ScrollView
>
</androidx.coordinatorlayout.widget.CoordinatorLayout>
\ No newline at end of file
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