提交 fd5b5252 编写于 作者: H hdx

ball: 调整样式和-+幅度

上级 01f4a6b2
...@@ -4,23 +4,20 @@ ...@@ -4,23 +4,20 @@
<text class="fps">FPS: {{fpsString}}</text> <text class="fps">FPS: {{fpsString}}</text>
<view class="item"> <view class="item">
<text class="item-label">Speed</text> <text class="item-label">Speed</text>
<text class="item-value">{{ballSpeed}}</text>
<view class="item-fill"></view>
<button size="mini" @click="lessClick('speed')">-</button> <button size="mini" @click="lessClick('speed')">-</button>
<text class="item-value">{{ballSpeed}}</text>
<button size="mini" @click="plusClick('speed')">+</button> <button size="mini" @click="plusClick('speed')">+</button>
</view> </view>
<view class="item"> <view class="item">
<text class="item-label">Layer</text> <text class="item-label">Layer</text>
<text class="item-value">{{ballLayer}}</text>
<view class="item-fill"></view>
<button size="mini" @click="lessClick('layer')">-</button> <button size="mini" @click="lessClick('layer')">-</button>
<text class="item-value">{{ballLayer}}</text>
<button size="mini" @click="plusClick('layer')">+</button> <button size="mini" @click="plusClick('layer')">+</button>
</view> </view>
<view class="item"> <view class="item">
<text class="item-label">Inlayer</text> <text class="item-label">Inlayer</text>
<text class="item-value">{{ballInlayer}}</text>
<view class="item-fill"></view>
<button size="mini" @click="lessClick('inLayer')">-</button> <button size="mini" @click="lessClick('inLayer')">-</button>
<text class="item-value">{{ballInlayer}}</text>
<button size="mini" @click="plusClick('inLayer')">+</button> <button size="mini" @click="plusClick('inLayer')">+</button>
</view> </view>
</view> </view>
...@@ -204,10 +201,10 @@ ...@@ -204,10 +201,10 @@
animation!.speed--; animation!.speed--;
ballSpeed.value = animation!.speed ballSpeed.value = animation!.speed
} else if (type == 'layer') { } else if (type == 'layer') {
animation!.layer--; animation!.layer -= 5;
ballLayer.value = animation!.layer ballLayer.value = animation!.layer
} else if (type == 'inLayer') { } else if (type == 'inLayer') {
animation!.inLayer--; animation!.inLayer -= 5;
ballInlayer.value = animation!.inLayer ballInlayer.value = animation!.inLayer
} }
} }
...@@ -217,10 +214,10 @@ ...@@ -217,10 +214,10 @@
animation!.speed++; animation!.speed++;
ballSpeed.value = animation!.speed ballSpeed.value = animation!.speed
} else if (type == 'layer') { } else if (type == 'layer') {
animation!.layer++; animation!.layer += 5;
ballLayer.value = animation!.layer ballLayer.value = animation!.layer
} else if (type == 'inLayer') { } else if (type == 'inLayer') {
animation!.inLayer++; animation!.inLayer += 5;
ballInlayer.value = animation!.inLayer ballInlayer.value = animation!.inLayer
} }
} }
...@@ -267,16 +264,12 @@ ...@@ -267,16 +264,12 @@
} }
.item-label { .item-label {
width: 120px; margin-right: auto;
} }
.item-value { .item-value {
margin-left: 5px;
color: cornflowerblue; color: cornflowerblue;
width: 50px; width: 50px;
} text-align: center;
.item-fill {
flex: 1;
} }
</style> </style>
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册