Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xiaoxiaole
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wildfirecode13
xiaoxiaole
Commits
d5a6821b
Commit
d5a6821b
authored
Oct 09, 2019
by
wildfirecode
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
ceaa0231
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
102 additions
and
0 deletions
+102
-0
MainBase.ts
egret/libs/new_wx/MainBase.ts
+2
-0
default.thm.json
egret/resource/default.thm.json
+2
-0
FriendItemSkin.exml
egret/resource/skins/FriendItemSkin.exml
+4
-0
FriendSkin.exml
egret/resource/skins/FriendSkin.exml
+36
-0
MapSkin.exml
egret/resource/skins/MapSkin.exml
+8
-0
MapScene.ts
egret/src/mapScene/MapScene.ts
+4
-0
FriendItemRenderer.ts
egret/src/panels/FriendItemRenderer.ts
+12
-0
FriendPanel.ts
egret/src/panels/FriendPanel.ts
+34
-0
No files found.
egret/libs/new_wx/MainBase.ts
View file @
d5a6821b
...
...
@@ -45,6 +45,7 @@ import TaskPanel from "../../src/panels/TaskPanel";
import
TaskPrizePanel
from
"../../src/panels/TaskPrizePanel"
;
import
BackPanel
from
"../../src/panels/BackPanel"
;
import
InvitePanel
from
"../../src/panels/InvitePanel"
;
import
FriendPanel
from
"../../src/panels/FriendPanel"
;
export
default
class
MainBase
extends
eui
.
UILayer
{
constructor
()
{
...
...
@@ -82,6 +83,7 @@ export default class MainBase extends eui.UILayer {
[
'taskPrize'
,
{
cls
:
TaskPrizePanel
}],
[
'back'
,
{
cls
:
BackPanel
}],
[
'invite'
,
{
cls
:
InvitePanel
}],
[
'friend'
,
{
cls
:
FriendPanel
}],
[
'ad'
,
{
cls
:
ADPanel
}],
];
...
...
egret/resource/default.thm.json
View file @
d5a6821b
...
...
@@ -42,6 +42,8 @@
"resource/skins/TargetItemSkin.exml"
,
"resource/skins/TaskItemSkin.exml"
,
"resource/skins/TaskSkin.exml"
,
"resource/skins/FriendSkin.exml"
,
"resource/skins/FriendItemSkin.exml"
,
"resource/skins/TaskPrizeSkin.exml"
,
"resource/skins/ADSkin.exml"
,
"resource/skins/BackSkin.exml"
,
...
...
egret/resource/skins/FriendItemSkin.exml
0 → 100644
View file @
d5a6821b
<?xml version="1.0" encoding="utf-8"?>
<e:Skin
class=
"FriendItemSkin"
width=
"400"
height=
"50"
xmlns:e=
"http://ns.egret.com/eui"
xmlns:w=
"http://ns.egret.com/wing"
>
<e:Label
id=
"nameTxt"
text=
"111"
x=
"20"
y=
"16"
/>
</e:Skin>
\ No newline at end of file
egret/resource/skins/FriendSkin.exml
0 → 100644
View file @
d5a6821b
<?xml version="1.0" encoding="utf-8"?>
<e:Skin
class=
"FriendSkin"
width=
"750"
height=
"1206"
xmlns:e=
"http://ns.egret.com/eui"
xmlns:w=
"http://ns.egret.com/wing"
>
<e:Image
source=
"闯关失败_png"
y=
"27"
horizontalCenter=
"0"
/>
<e:Button
id=
"closeBtn"
label=
""
x=
"609"
y=
"197"
>
<e:skinName>
<e:Skin
states=
"up,down,disabled"
xmlns:w=
"http://ns.egret.com/wing"
>
<e:Image
width=
"100%"
height=
"100%"
source=
"closeCommonBtn_png"
source.down=
"closeCommonBtn_png"
source.disabled=
"closeCommonBtn_png"
/>
<e:Label
id=
"labelDisplay"
horizontalCenter=
"0"
verticalCenter=
"0"
/>
</e:Skin>
</e:skinName>
</e:Button>
<e:Scroller
id=
"scroll"
width=
"400"
height=
"400"
y=
"279"
horizontalCenter=
"0"
scrollPolicyV=
"on"
scrollPolicyH=
"off"
>
<e:Group>
<e:List
id=
"list"
width=
"100%"
itemRendererSkinName=
"FriendItemSkin"
>
<e:ArrayCollection>
<e:Array>
<e:Object
a=
"taskname1"
/>
<e:Object
a=
"taskname2"
/>
<e:Object
a=
"taskname3"
/>
<e:Object
a=
"null"
/>
<e:Object
a=
"null"
/>
<e:Object
a=
"null"
/>
<e:Object
a=
"null"
/>
<e:Object
a=
"null"
/>
<e:Object
a=
"null"
/>
<e:Object
a=
"null"
/>
</e:Array>
</e:ArrayCollection>
<e:layout>
<e:VerticalLayout
gap=
"0"
/>
</e:layout>
</e:List>
</e:Group>
</e:Scroller>
<e:Label
text=
"friendBtn"
x=
"80"
y=
"468"
/>
</e:Skin>
\ No newline at end of file
egret/resource/skins/MapSkin.exml
View file @
d5a6821b
...
...
@@ -83,6 +83,14 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Button
id=
"friendBtn"
label=
""
x=
"185"
y=
"158.57"
>
<e:skinName>
<e:Skin
states=
"up,down,disabled"
>
<e:Image
width=
"100%"
height=
"100%"
source=
"recordbtn_png"
source.down=
"recordbtn_png"
source.disabled=
"recordbtn_png"
/>
<e:Label
id=
"labelDisplay"
horizontalCenter=
"0"
verticalCenter=
"0"
/>
</e:Skin>
</e:skinName>
</e:Button>
<e:Button
id=
"inviteBtn"
label=
""
x=
"608.17"
y=
"460.41"
>
<e:skinName>
<e:Skin
states=
"up,down,disabled"
>
...
...
egret/src/mapScene/MapScene.ts
View file @
d5a6821b
...
...
@@ -317,6 +317,9 @@ export default class MapScene extends Scene {
onTap_inviteBtn
(){
PanelCtrl
.
instance
.
show
(
'invite'
);
}
onTap_friendBtn
(){
PanelCtrl
.
instance
.
show
(
'friend'
);
}
onTap_adBtn
(){
console
.
log
(
'onTap_adBtn'
)
}
...
...
@@ -329,6 +332,7 @@ export default class MapScene extends Scene {
protected
initEvents
()
{
// this['goldBtn'].addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTap_goldBtn, this)
this
[
'inviteBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
this
.
onTap_inviteBtn
,
this
)
this
[
'friendBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
this
.
onTap_friendBtn
,
this
)
this
[
'adBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
this
.
onTap_adBtn
,
this
)
this
[
'taskBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
this
.
onTap_taskBtn
,
this
)
this
[
'signBtn'
].
addEventListener
(
egret
.
TouchEvent
.
TOUCH_TAP
,
this
.
onTap_signBtn
,
this
)
...
...
egret/src/panels/FriendItemRenderer.ts
0 → 100644
View file @
d5a6821b
import
getSkinPath
from
"../../libs/new_wx/utils/getSkinPath"
;
export
default
class
FriendItemRenderer
extends
eui
.
ItemRenderer
{
constructor
()
{
super
();
this
.
skinName
=
getSkinPath
(
'FriendItem'
);
}
dataChanged
(){
this
[
'nameTxt'
].
text
=
this
.
data
+
''
;
}
}
\ No newline at end of file
egret/src/panels/FriendPanel.ts
0 → 100644
View file @
d5a6821b
import
Panel
from
"../../libs/new_wx/components/Panel"
;
import
FriendItemRenderer
from
"./FriendItemRenderer"
;
export
default
class
FriendPanel
extends
Panel
{
public
list
:
eui
.
List
;
start
(
data
)
{
super
.
start
();
this
.
showlog
();
this
.
list
.
useVirtualLayout
=
false
;
this
.
list
.
itemRenderer
=
FriendItemRenderer
;
const
ac
=
new
eui
.
ArrayCollection
([
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
]);
this
.
list
.
dataProvider
=
ac
;
}
showlog
(){
// NetManager.ins.showLog(getlogItem(3));
// NetManager.ins.showLog(getlogItem(4));
}
initEvents
()
{
super
.
initEvents
();
// this['inviteBtn'].addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTapInvite, this)
}
onTapInvite
()
{
}
protected
get
closeBtns
():
eui
.
Button
[]
{
return
[
this
[
'closeBtn'
]]
}
get
skinKey
()
{
return
'Friend'
}
}
\ 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