Browse Source

lyw 上传

授权码生成工具
lyw 5 months ago
parent
commit
7c356a547a
5 changed files with 69 additions and 25 deletions
  1. +16
    -0
      app/src/main/java/com/bonait/bnframework/common/model/mode/MouthFacingEnum_en.java
  2. +19
    -10
      app/src/main/java/com/bonait/bnframework/modules/home/fragment/HomeFragmentSBKZ.java
  3. +13
    -12
      app/src/main/res/layout/fragment_home_sbkz.xml
  4. +11
    -2
      app/src/main/res/values-en/strings.xml
  5. +10
    -1
      app/src/main/res/values/strings.xml

+ 16
- 0
app/src/main/java/com/bonait/bnframework/common/model/mode/MouthFacingEnum_en.java View File

@@ -0,0 +1,16 @@
package com.bonait.bnframework.common.model.mode;

public enum MouthFacingEnum_en {
Original,

Fried,

Maintenance,

Extraction,

Pour,

Clean

}

+ 19
- 10
app/src/main/java/com/bonait/bnframework/modules/home/fragment/HomeFragmentSBKZ.java View File

@@ -31,6 +31,7 @@ import com.bonait.bnframework.common.helper.I.IRun;
import com.bonait.bnframework.common.helper.I.IWriteCallBack;
import com.bonait.bnframework.common.helper.I.MyClickListener;
import com.bonait.bnframework.common.model.mode.MouthFacingEnum;
import com.bonait.bnframework.common.model.mode.MouthFacingEnum_en;
import com.bonait.bnframework.common.model.mode.SpeedEnum;
import com.bonait.bnframework.common.model.mode.SpeedEnum_en;
import com.bonait.bnframework.common.utils.AlertDialogUtils;
@@ -259,7 +260,7 @@ public class HomeFragmentSBKZ extends BaseFragment {
SetIDTouch(R.id.yeliao1, false);
}
} else {
ToastUtils.warning("请先控制锅口朝向:抽料位");
ToastUtils.warning(getString(R.string.text_potdirection));
SetIDTouch(R.id.yeliao1, false);
}
return false;
@@ -276,7 +277,7 @@ public class HomeFragmentSBKZ extends BaseFragment {
SetIDTouch(R.id.yeliao2, false);
}
} else {
ToastUtils.warning("请先控制锅口朝向:抽料位");
ToastUtils.warning(getString(R.string.text_potdirection));
SetIDTouch(R.id.yeliao2, false);
}
return false;
@@ -293,7 +294,7 @@ public class HomeFragmentSBKZ extends BaseFragment {
SetIDTouch(R.id.yeliao3, false);
}
} else {
ToastUtils.warning("请先控制锅口朝向:抽料位");
ToastUtils.warning(getString(R.string.text_potdirection));
SetIDTouch(R.id.yeliao3, false);
}
return false;
@@ -635,33 +636,41 @@ public class HomeFragmentSBKZ extends BaseFragment {
switch (mouth) {
case 炒菜位:
ExecuteTheRecipe.BottomClick("炒菜位1");
guokoucaoxiang.setTag("锅口朝向\n 炒菜位-按钮");
guokoucaoxiang.setTag(getString(R.string.btn_pot)+"\n"+getString(R.string.btn_fry));
break;
case 维护位:
ExecuteTheRecipe.BottomClick("维护位");
guokoucaoxiang.setTag("锅口朝向\n 维护位-按钮");
guokoucaoxiang.setTag(getString(R.string.btn_pot)+"\n"+getString(R.string.btn_maintain));
break;
case 抽料位:
ExecuteTheRecipe.BottomClick("抽料位");
guokoucaoxiang.setTag("锅口朝向\n 抽料位-按钮");
guokoucaoxiang.setTag(getString(R.string.btn_pot)+"\n"+getString(R.string.btn_extract));
break;
case 倒菜位:
ExecuteTheRecipe.BottomClick("倒菜位");
guokoucaoxiang.setTag("锅口朝向\n 倒菜位-按钮");
guokoucaoxiang.setTag(getString(R.string.btn_pot)+"\n"+getString(R.string.btn_pour));
break;
case 清洗位:
ExecuteTheRecipe.BottomClick("清洗位");
guokoucaoxiang.setTag("锅口朝向\n 清洗位-按钮");
guokoucaoxiang.setTag(getString(R.string.btn_pot)+"\n"+getString(R.string.btn_clean));
break;
case 原点位:
ExecuteTheRecipe.BottomClick("原点位");
guokoucaoxiang.setTag("锅口朝向\n 原点位-按钮");
guokoucaoxiang.setTag(getString(R.string.btn_pot)+"\n"+getString(R.string.btn_origin));
break;
}
guokoucaoxiang_1.setVisibility(View.GONE);
guokoucaoxiang.Init();
switch (getString(R.string.language)){
case "en":
int t = mouth.ordinal();
ToastUtils.warning("Current Pot Direction:" + MouthFacingEnum_en.values()[t]+" Position");
break;
case "zh":
ToastUtils.warning("当前锅口朝向:" + mouth.name());
break;
}

ToastUtils.warning("当前锅口朝向:" + mouth.name());
}

/**


+ 13
- 12
app/src/main/res/layout/fragment_home_sbkz.xml View File

@@ -146,7 +146,7 @@
android:layout_width="160dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="@string/btn_fry"
android:tag="@string/btn_fry_sp"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -350,7 +350,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="洗锅水枪-按钮"
android:tag="@string/btn_watergun"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -360,7 +360,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="锅内加水-按钮"
android:tag="@string/btn_addwater"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -413,15 +413,16 @@
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_marginTop="40dp"
android:layout_marginRight="140dp"
android:layout_marginRight="150dp"
android:gravity="end"
android:orientation="vertical">

<com.bonait.bnframework.modules.home.fragment.mode.imagebuttom3
android:id="@+id/guokoucaoxiang"
android:layout_width="100dp"
android:layout_width="140dp"
android:layout_height="80dp"
android:contentDescription="true"
android:tag="锅口朝向-按钮"
android:tag="@string/btn_pot"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -438,7 +439,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="原点位-按钮"
android:tag="@string/btn_origin"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -448,7 +449,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="维护位-按钮"
android:tag="@string/btn_maintain"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -457,7 +458,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="炒菜位-按钮"
android:tag="@string/btn_fry"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -467,7 +468,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="抽料位-按钮"
android:tag="@string/btn_extract"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -477,7 +478,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="倒菜位-按钮"
android:tag="@string/btn_pour"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />
@@ -487,7 +488,7 @@
android:layout_width="100dp"
android:layout_height="60dp"
android:contentDescription="true"
android:tag="清洗位-按钮"
android:tag="@string/btn_clean"
app:imagesrc_ks="@mipmap/sb1"
app:imagesrc_qt="@mipmap/sb2"
app:imagesrc_tz="@mipmap/sb3" />


+ 11
- 2
app/src/main/res/values-en/strings.xml View File

@@ -58,7 +58,7 @@
<string name="btn_exit">Exit</string>
<string name="btn_recipe">Recipe</string>
<string name="btn_device">Device</string>
<string name="btn_fry">Stir-fry speed-按钮</string>
<string name="btn_fry_sp">Stir-fry speed-按钮</string>
<string name="btn_fry_fast">Stir-fry Fast-按钮</string>
<string name="btn_fry_middle">Stir-fry Middle-按钮</string>
<string name="btn_fry_slow">Stir-fry Slow-按钮</string>
@@ -68,5 +68,14 @@
<string name="btn_slow">Slow</string>
<string name="btn_stop">Stop</string>
<string name="btn_pot">Pot Direction-按钮</string>
<string name="btn_origin">Pot Direction-按钮</string>
<string name="btn_origin">Original-按钮</string>
<string name="btn_maintain">Maintain-按钮</string>
<string name="btn_fry">Fry-按钮</string>
<string name="btn_extract">Extract-按钮</string>
<string name="btn_pour">Pour-按钮</string>
<string name="btn_clean">Clean-按钮</string>
<string name="btn_watergun">Water Gun-按钮</string>
<string name="btn_addwater">Add Water-按钮</string>
<string name="text_potdirection">Please control the pan direction: Extraction Position</string>

</resources>

+ 10
- 1
app/src/main/res/values/strings.xml View File

@@ -58,7 +58,7 @@
<string name="btn_exit">注销</string>
<string name="btn_recipe">菜谱</string>
<string name="btn_device">设备</string>
<string name="btn_fry">翻炒速度-按钮</string>
<string name="btn_fry_sp">翻炒速度-按钮</string>
<string name="btn_fry_fast">翻炒速度 快-按钮</string>
<string name="btn_fry_middle">翻炒速度 中-按钮</string>
<string name="btn_fry_slow">翻炒速度 慢-按钮</string>
@@ -68,4 +68,13 @@
<string name="btn_slow">慢</string>
<string name="btn_stop">停</string>
<string name="btn_pot">锅口朝向-按钮</string>
<string name="btn_origin">原点位-按钮</string>
<string name="btn_maintain">维护位-按钮</string>
<string name="btn_fry">炒菜位-按钮</string>
<string name="btn_extract">抽料位-按钮</string>
<string name="btn_pour">倒菜位-按钮</string>
<string name="btn_clean">清洗位-按钮</string>
<string name="btn_watergun">洗锅水枪-按钮</string>
<string name="btn_addwater">锅内加水-按钮</string>
<string name="text_potdirection">请先控制锅口朝向:抽料位</string>
</resources>

Loading…
Cancel
Save