Commit 9b4952ad by wjg

v2

parent 096107cd
......@@ -3,7 +3,7 @@ package com.ihaoin.hooloo.device.base;
import com.ihaoin.hooloo.device.data.enums.PresentState;
public class AppConfig {
public static Boolean DEBUG = true; // TODO 编译环境
public static Boolean DEBUG = false; // TODO 编译环境
/** 点单屏编码, 1-菜单屏,2-交互屏 */
public static String DEFAULT_SCREEN_NO = "1"; // TODO 编译点单屏编码
/** 副屏内容 */
......@@ -26,6 +26,6 @@ public class AppConfig {
public static String WX_URL_TEST = "http://hooloo.gdatac.com/c2?id=%s";
public static String HOST = "";
public static final String HOST_PROD = "https://hooloo-api.gdatac.com/";
public static final String HOST_TEST = "https://hooloo-dev-api.gdatac.com/";
public static final String HOST_PROD = "https://api.ihaoin.com";
public static final String HOST_TEST = "https://hooloo-dev-api.gdatac.com";
}
......@@ -119,10 +119,10 @@ public class LauncherActivity extends Activity {
initSettingsQueue();
// startUpdateSocket();
startMachineClient();
startTimeoutThread();
getMachineCode();
// startUpdateSocket();
// new UpdateService().start();
}
......
......@@ -78,7 +78,21 @@ public class InteractionPresentation extends Presentation {
view1.setVisibility(View.VISIBLE);
view2.setVisibility(View.INVISIBLE);
startPlay();
Glide.with(getContext()).asGif().load("https://testapi.pecktoy.com/files/upload_test/he.gif").into(new CustomTarget<GifDrawable>() {
@Override
public void onResourceReady(@NonNull GifDrawable resource, @Nullable Transition transition) {
foreground.setVisibility(View.VISIBLE);
foreground.setImageDrawable(resource);
resource.start();
}
@Override
public void onLoadCleared(@Nullable Drawable placeholder) {
}
});
// startPlay();
}
private void setInteractionMsg(InteractionMsg msg) {
......@@ -288,7 +302,21 @@ public class InteractionPresentation extends Presentation {
Utils.i("interaction msg is null");
return;
}
setInteractionMsg(msg);
// setInteractionMsg(msg);
Glide.with(getContext()).asGif().load(msg.getBackground()).into(new CustomTarget<GifDrawable>() {
@Override
public void onResourceReady(@NonNull GifDrawable resource, @Nullable Transition transition) {
foreground.setVisibility(View.VISIBLE);
foreground.setImageDrawable(resource);
resource.start();
}
@Override
public void onLoadCleared(@Nullable Drawable placeholder) {
}
});
}
}
......
......@@ -233,7 +233,7 @@ public class KdsPresentation extends Presentation {
private Integer statePosition = 3;
private void setNextImage() {
if (imagePagerAdapter == null || imagePagerAdapter.getItemCount() <= 0) {
if (imagePagerAdapter == null || imagePagerAdapter.getItemCount() <= 1) {
return;
}
imagePosition++;
......
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/holo_red_dark">
android:layout_height="match_parent">
<ImageView
android:id="@+id/img_background1"
android:layout_width="match_parent"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment