Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
YGOMobile-Cn-Ko-En
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-Cn-Ko-En
Commits
641f9bd9
Commit
641f9bd9
authored
Apr 15, 2020
by
fallenstardust
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CallBack 搜索器Activity
parent
ba675edd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
2 deletions
+7
-2
mobile/src/main/java/cn/garymb/ygomobile/ui/cards/CardSearchActivityImpl.java
.../cn/garymb/ygomobile/ui/cards/CardSearchActivityImpl.java
+2
-1
mobile/src/main/java/cn/garymb/ygomobile/ui/cards/CardSearcher.java
.../main/java/cn/garymb/ygomobile/ui/cards/CardSearcher.java
+5
-1
No files found.
mobile/src/main/java/cn/garymb/ygomobile/ui/cards/CardSearchActivityImpl.java
View file @
641f9bd9
...
@@ -40,7 +40,7 @@ import ocgcore.StringManager;
...
@@ -40,7 +40,7 @@ import ocgcore.StringManager;
import
ocgcore.data.Card
;
import
ocgcore.data.Card
;
import
ocgcore.data.LimitList
;
import
ocgcore.data.LimitList
;
class
CardSearchActivityImpl
extends
BaseActivity
implements
CardLoader
.
CallBack
{
class
CardSearchActivityImpl
extends
BaseActivity
implements
CardLoader
.
CallBack
,
CardSearcher
.
CallBack
{
protected
DrawerLayout
mDrawerlayout
;
protected
DrawerLayout
mDrawerlayout
;
protected
CardSearcher
mCardSelector
;
protected
CardSearcher
mCardSelector
;
...
@@ -95,6 +95,7 @@ class CardSearchActivityImpl extends BaseActivity implements CardLoader.CallBack
...
@@ -95,6 +95,7 @@ class CardSearchActivityImpl extends BaseActivity implements CardLoader.CallBack
mCardLoader
=
new
CardLoader
(
this
);
mCardLoader
=
new
CardLoader
(
this
);
mCardLoader
.
setCallBack
(
this
);
mCardLoader
.
setCallBack
(
this
);
mCardSelector
=
new
CardSearcher
(
$
(
R
.
id
.
nav_view_list
),
mCardLoader
);
mCardSelector
=
new
CardSearcher
(
$
(
R
.
id
.
nav_view_list
),
mCardLoader
);
mCardSelector
.
setCallBack
(
this
);
setListeners
();
setListeners
();
DialogPlus
dlg
=
DialogPlus
.
show
(
this
,
null
,
getString
(
R
.
string
.
loading
));
DialogPlus
dlg
=
DialogPlus
.
show
(
this
,
null
,
getString
(
R
.
string
.
loading
));
VUiKit
.
defer
().
when
(()
->
{
VUiKit
.
defer
().
when
(()
->
{
...
...
mobile/src/main/java/cn/garymb/ygomobile/ui/cards/CardSearcher.java
View file @
641f9bd9
...
@@ -80,6 +80,8 @@ public class CardSearcher implements View.OnClickListener {
...
@@ -80,6 +80,8 @@ public class CardSearcher implements View.OnClickListener {
CardLoader
mCardLoader
;
CardLoader
mCardLoader
;
public
interface
CallBack
{
public
interface
CallBack
{
void
onSearchStart
();
void
onSearchResult
(
List
<
Card
>
Cards
,
boolean
isHide
);
void
onSearchResult
(
List
<
Card
>
Cards
,
boolean
isHide
);
}
}
...
@@ -147,8 +149,10 @@ public class CardSearcher implements View.OnClickListener {
...
@@ -147,8 +149,10 @@ public class CardSearcher implements View.OnClickListener {
for
(
int
i
=
0
;
i
<
id
.
size
();
i
++)
for
(
int
i
=
0
;
i
<
id
.
size
();
i
++)
Favorite
.
add
(
id
.
valueAt
(
i
));
Favorite
.
add
(
id
.
valueAt
(
i
));
}
}
if
(
mCallBack
!=
null
)
if
(
mCallBack
!=
null
)
{
mCallBack
.
onSearchStart
();
mCallBack
.
onSearchResult
(
Favorite
,
false
);
mCallBack
.
onSearchResult
(
Favorite
,
false
);
}
DeckManagerActivityImpl
.
isSearchResult
=
false
;
DeckManagerActivityImpl
.
isSearchResult
=
false
;
}
}
...
...
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