根据测试反馈修改帮助反馈问题
新增小游戏跳一跳回血和必中的回调 新增关闭发红包页面后自动打开礼物栏的功能 调整小游戏跳一跳回调防抖
This commit is contained in:
parent
1c9493d7c8
commit
1f12187766
@ -454,7 +454,7 @@ public class CommonHttpUtil {
|
||||
* 上传文件 获取七牛云token的接口
|
||||
*/
|
||||
public static void getUploadQiNiuToken(HttpCallback callback, boolean isImg) {
|
||||
HttpClient.getInstance().get("Pdluserhome.getQiNiuToken", "Pdluserhome.getQiNiuToken")
|
||||
HttpClient.getInstance().get("Pdluserhome.getQiNiuToken2", "Pdluserhome.getQiNiuToken2")
|
||||
.params("uid", CommonAppConfig.getInstance().getUid())
|
||||
.params("token", CommonAppConfig.getInstance().getToken())
|
||||
.params("ext", isImg ? ".jpeg" : ".mp4")
|
||||
|
@ -1210,4 +1210,26 @@ public interface PDLiveApi {
|
||||
|
||||
@GET("/api/public/?service=User.userFeedbackRestrict")
|
||||
Observable<ResponseModel<List<BaseModel>>> checkFeedback();
|
||||
|
||||
/**
|
||||
*
|
||||
* @param roomId 房间ID
|
||||
* @param cmd 事件名称 生命值:addHeart 自动跳:hit
|
||||
* @param value 价格
|
||||
* @param gameId 游戏ID
|
||||
* @param fromUid 付费用户uid
|
||||
* @param toUid 目标用户uid
|
||||
* @param payload 附加值
|
||||
* @return
|
||||
*/
|
||||
@GET("/api/public/?service=Sudgameserver.createOrder")
|
||||
Observable<ResponseModel<List<BaseModel>>> createGameOrder(
|
||||
@Query("room_id")String roomId,
|
||||
@Query("cmd")String cmd,
|
||||
@Query("value")String value,
|
||||
@Query("mg_id")String gameId,
|
||||
@Query("from_uid")String fromUid,
|
||||
@Query("to_uid")String toUid,
|
||||
@Query("payload")String payload
|
||||
);
|
||||
}
|
||||
|
@ -95,6 +95,7 @@ import io.reactivex.schedulers.Schedulers;
|
||||
import okhttp3.MediaType;
|
||||
import okhttp3.MultipartBody;
|
||||
import okhttp3.RequestBody;
|
||||
import retrofit2.http.Query;
|
||||
|
||||
|
||||
/**
|
||||
@ -3245,6 +3246,40 @@ public class LiveNetManager {
|
||||
}).isDisposed();
|
||||
}
|
||||
|
||||
public void createGameOrder(
|
||||
String roomId,
|
||||
String cmd,
|
||||
String value,
|
||||
String gameId,
|
||||
String fromUid,
|
||||
String toUid,
|
||||
String roundId,
|
||||
String payload
|
||||
, HttpCallback<HttpCallbackModel> callback) {
|
||||
API.get().pdLiveApi(mContext)
|
||||
.createGameOrder(roomId, cmd, value, gameId, fromUid, toUid,payload)
|
||||
.subscribeOn(Schedulers.io())
|
||||
.observeOn(AndroidSchedulers.mainThread())
|
||||
.subscribe(new Consumer<ResponseModel<List<BaseModel>>>() {
|
||||
@Override
|
||||
public void accept(ResponseModel<List<BaseModel>> responseModel) {
|
||||
if (callback != null) {
|
||||
HttpCallbackModel model = new HttpCallbackModel();
|
||||
model.setCode(responseModel.getData().getCode());
|
||||
model.setMsg(responseModel.getData().getMsg());
|
||||
callback.onSuccess(model);
|
||||
}
|
||||
}
|
||||
}, new Consumer<Throwable>() {
|
||||
@Override
|
||||
public void accept(Throwable throwable) throws Exception {
|
||||
if (callback != null) {
|
||||
callback.onError(mContext.getString(com.yunbao.common.R.string.net_error));
|
||||
}
|
||||
}
|
||||
}).isDisposed();
|
||||
}
|
||||
|
||||
private MultipartBody.Part createUploadFile(File file) {
|
||||
RequestBody requestBody = RequestBody.create(MediaType.parse("multipart/form-data"), file);
|
||||
return MultipartBody.Part.createFormData("file", file.getName(), requestBody);
|
||||
|
@ -47,7 +47,7 @@ public abstract class ImageResultCallback {
|
||||
UploadQnImpl mUploadStrategy = new UploadQnImpl(mContext);
|
||||
List<UploadBean> beans = new ArrayList<>();
|
||||
beans.add(new UploadBean(file, UploadBean.IMG));
|
||||
mUploadStrategy.upload(beans, false, new UploadCallback() {
|
||||
mUploadStrategy.upload(beans, true, new UploadCallback() {
|
||||
@Override
|
||||
public void onFinish(List<UploadBean> list, boolean success) {
|
||||
if (success) {
|
||||
|
@ -142,7 +142,10 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
|
||||
|
||||
// 给装饰类设置回调
|
||||
sudFSMMGDecorator.setSudFSMMGListener(this);
|
||||
|
||||
sudFSMMGDecorator.setGameId(gameId);
|
||||
sudFSMMGDecorator.setRoomId(gameRoomId);
|
||||
sudFSMMGDecorator.setUserId(getUserId());
|
||||
Log.i("游戏回调",code+" "+gameId+" "+gameRoomId+" ");
|
||||
// 调用游戏sdk加载游戏
|
||||
ISudFSTAPP iSudFSTAPP = SudMGP.loadMG(activity, getUserId(), gameRoomId, code, gameId, getLanguageCode(), sudFSMMGDecorator);
|
||||
|
||||
|
@ -23,6 +23,10 @@ import tech.sud.mgp.core.ISudFSMStateHandle;
|
||||
*/
|
||||
public class SudFSMMGDecorator implements ISudFSMMG {
|
||||
|
||||
private static final String TAG = "游戏回调";
|
||||
private long gameId;
|
||||
private String gameRoomId;
|
||||
private String userId;
|
||||
// 回调
|
||||
private SudFSMMGListener sudFSMMGListener;
|
||||
|
||||
@ -354,6 +358,13 @@ public class SudFSMMGDecorator implements ISudFSMMG {
|
||||
break;
|
||||
case SudMGPMGState.MG_COMMON_GAME_CREATE_ORDER: // 25. 创建订单
|
||||
SudMGPMGState.MGCommonGameCreateOrder mgCommonGameCreateOrder = SudJsonUtils.fromJson(dataJson, SudMGPMGState.MGCommonGameCreateOrder.class);
|
||||
if (mgCommonGameCreateOrder != null) {
|
||||
mgCommonGameCreateOrder.gameId = gameId;
|
||||
mgCommonGameCreateOrder.gameRoomId = gameRoomId;
|
||||
mgCommonGameCreateOrder.userId = userId;
|
||||
}
|
||||
|
||||
Log.i(TAG, "onGameStateChange: " + dataJson);
|
||||
if (listener == null) {
|
||||
ISudFSMStateHandleUtils.handleSuccess(handle);
|
||||
} else {
|
||||
@ -1021,4 +1032,15 @@ public class SudFSMMGDecorator implements ISudFSMMG {
|
||||
return sudFSMMGCache;
|
||||
}
|
||||
|
||||
public void setGameId(long gameId) {
|
||||
this.gameId = gameId;
|
||||
}
|
||||
|
||||
public void setRoomId(String gameRoomId) {
|
||||
this.gameRoomId = gameRoomId;
|
||||
}
|
||||
|
||||
public void setUserId(String userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
}
|
||||
|
@ -5,6 +5,7 @@
|
||||
|
||||
package com.yunbao.common.sud.decorator;
|
||||
|
||||
import com.yunbao.common.sud.decorator.game.JumpEvent;
|
||||
import com.yunbao.common.sud.state.SudMGPMGState;
|
||||
import com.yunbao.common.utils.ISudFSMStateHandleUtils;
|
||||
|
||||
@ -271,8 +272,14 @@ public interface SudFSMMGListener {
|
||||
* mg_common_game_create_order
|
||||
*/
|
||||
default void onGameMGCommonGameCreateOrder(ISudFSMStateHandle handle, SudMGPMGState.MGCommonGameCreateOrder model) {
|
||||
if ("addHeart".equals(model.cmd)) {
|
||||
JumpEvent.addHeart(model);
|
||||
} else if ("hit".equals(model.cmd)) {
|
||||
JumpEvent.hit(model);
|
||||
} else {
|
||||
ISudFSMStateHandleUtils.handleSuccess(handle);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 26. 游戏通知app玩家角色(仅对狼人杀有效)
|
||||
|
@ -0,0 +1,47 @@
|
||||
package com.yunbao.common.sud.decorator.game;
|
||||
|
||||
import com.yunbao.common.bean.HttpCallbackModel;
|
||||
import com.yunbao.common.http.base.HttpCallback;
|
||||
import com.yunbao.common.http.live.LiveNetManager;
|
||||
import com.yunbao.common.sud.state.SudMGPMGState;
|
||||
import com.yunbao.common.utils.AppManager;
|
||||
|
||||
public class JumpEvent {
|
||||
private static long clickTimer = 0;
|
||||
|
||||
public static void addHeart(SudMGPMGState.MGCommonGameCreateOrder order) {
|
||||
createOrder(order);
|
||||
}
|
||||
|
||||
public static void hit(SudMGPMGState.MGCommonGameCreateOrder order) {
|
||||
createOrder(order);
|
||||
}
|
||||
|
||||
private synchronized static void createOrder(SudMGPMGState.MGCommonGameCreateOrder order) {
|
||||
if (System.currentTimeMillis() - clickTimer < 1000) {
|
||||
//TODO 防止重复点击
|
||||
return;
|
||||
}
|
||||
clickTimer = System.currentTimeMillis();
|
||||
LiveNetManager.get(AppManager.getInstance().getLastActivity())
|
||||
.createGameOrder(order.gameRoomId,
|
||||
order.cmd,
|
||||
order.value + "",
|
||||
order.gameId + "",
|
||||
order.fromUid,
|
||||
order.toUid,
|
||||
order.gameRoomId,
|
||||
order.payload,
|
||||
new HttpCallback<HttpCallbackModel>() {
|
||||
@Override
|
||||
public void onSuccess(HttpCallbackModel data) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(String error) {
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
@ -496,6 +496,10 @@ public class SudMGPMGState implements Serializable {
|
||||
public String toUid; // 目标用户uid
|
||||
public long value; // 所属的游戏价值
|
||||
public String payload; // 扩展数据 json 字符串, 特殊可选
|
||||
|
||||
public long gameId;
|
||||
public String gameRoomId;
|
||||
public String userId;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1,20 +1,12 @@
|
||||
package com.yunbao.common.utils;
|
||||
|
||||
import static com.yalantis.ucrop.util.FileUtils.getDataColumn;
|
||||
|
||||
import android.Manifest;
|
||||
import android.content.ContentUris;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.database.Cursor;
|
||||
import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.os.Environment;
|
||||
import android.provider.DocumentsContract;
|
||||
import android.provider.DocumentsProvider;
|
||||
import android.provider.MediaStore;
|
||||
|
||||
import androidx.documentfile.provider.DocumentFile;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.core.content.FileProvider;
|
||||
|
||||
@ -46,6 +38,11 @@ public class ProcessImageUtil extends ProcessResultUtil {
|
||||
private File mCorpResult;//裁剪后得到的图片
|
||||
private ImageResultCallback mResultCallback;
|
||||
private boolean mNeedCrop;//是否需要裁剪
|
||||
private boolean mNeedGif;//允许gif图
|
||||
|
||||
public void setNeedGif(boolean mNeedGif) {
|
||||
this.mNeedGif = mNeedGif;
|
||||
}
|
||||
|
||||
public ProcessImageUtil(FragmentActivity activity) {
|
||||
super(activity);
|
||||
@ -103,6 +100,9 @@ public class ProcessImageUtil extends ProcessResultUtil {
|
||||
@Override
|
||||
public void onFailure() {
|
||||
ToastUtil.show(mContext.getString(R.string.img_camera_cancel));
|
||||
if (mResultCallback != null) {
|
||||
mResultCallback.onFailure();
|
||||
}
|
||||
}
|
||||
};
|
||||
mAlumbResultCallback = new ActivityResultCallback() {
|
||||
@ -221,9 +221,14 @@ public class ProcessImageUtil extends ProcessResultUtil {
|
||||
* 打开相册,选择文件
|
||||
*/
|
||||
private void chooseFile() {
|
||||
String[] mimeTypes = {"image/png", "image/jpg", "image/jpeg"};
|
||||
Intent intent = new Intent();
|
||||
intent.addCategory(Intent.CATEGORY_OPENABLE);
|
||||
intent.setType("image/*");
|
||||
intent.setType("*/*");
|
||||
if (mNeedGif) {
|
||||
mimeTypes = new String[]{"image/png", "image/jpg", "image/jpeg", "image/gif"};
|
||||
}
|
||||
intent.putExtra(Intent.EXTRA_MIME_TYPES, mimeTypes);
|
||||
if (Build.VERSION.SDK_INT < 19) {
|
||||
intent.setAction(Intent.ACTION_GET_CONTENT);
|
||||
} else {
|
||||
|
@ -21,7 +21,7 @@ ext {
|
||||
baiduAppSecretKey: "nEVSgmuGpU0pjPr6VleEGGAl0hzGW52S",
|
||||
|
||||
// true表示谷歌支付 false 0 链接包 1 谷歌包 2华为包 3 samsung包
|
||||
isGooglePlay : 3,
|
||||
isGooglePlay : 0,
|
||||
//是否上报异常日志
|
||||
isUploadLog : true,
|
||||
//是否打包成插件包模式
|
||||
|
@ -2,7 +2,9 @@ package com.yunbao.live.dialog;
|
||||
|
||||
import static com.yunbao.common.utils.RouteUtil.PATH_COIN;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
import android.content.DialogInterface;
|
||||
import android.graphics.Color;
|
||||
import android.text.Editable;
|
||||
import android.text.TextUtils;
|
||||
@ -19,10 +21,12 @@ import com.lxj.xpopup.core.CenterPopupView;
|
||||
import com.umeng.analytics.MobclickAgent;
|
||||
import com.yunbao.common.http.base.HttpCallback;
|
||||
import com.yunbao.common.http.live.LiveNetManager;
|
||||
import com.yunbao.common.utils.Bus;
|
||||
import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
import com.yunbao.common.views.weight.ViewClicksAntiShake;
|
||||
import com.yunbao.live.R;
|
||||
import com.yunbao.live.event.LiveAudienceEvent;
|
||||
|
||||
public class SendRendPacketPopup extends CenterPopupView {
|
||||
private Button thereIsNo, followingAnchor, joinFansGroup;
|
||||
@ -31,6 +35,8 @@ public class SendRendPacketPopup extends CenterPopupView {
|
||||
private FrameLayout redPacketIllustrate;
|
||||
private ImageView iconInstructions, illustrateClose;
|
||||
private String mLiveID, conditions = "0";
|
||||
private DialogInterface onDismissListener;
|
||||
private boolean sendSuccess;
|
||||
|
||||
public SendRendPacketPopup(@NonNull Context context, String liveID) {
|
||||
super(context);
|
||||
@ -51,6 +57,23 @@ public class SendRendPacketPopup extends CenterPopupView {
|
||||
initView();
|
||||
}
|
||||
|
||||
public void setOnDismissListener(DialogInterface onDismissListener) {
|
||||
this.onDismissListener = onDismissListener;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDismiss() {
|
||||
super.onDismiss();
|
||||
|
||||
if (sendSuccess) {
|
||||
// onDismissListener.dismiss();
|
||||
} else {
|
||||
// onDismissListener.cancel();
|
||||
Bus.get().post(new LiveAudienceEvent()
|
||||
.setType(LiveAudienceEvent.LiveAudienceType.GIFT_POPUP));
|
||||
}
|
||||
}
|
||||
|
||||
private void initView() {
|
||||
thereIsNo = findViewById(R.id.there_is_no);
|
||||
followingAnchor = findViewById(R.id.following_anchor);
|
||||
@ -222,6 +245,7 @@ public class SendRendPacketPopup extends CenterPopupView {
|
||||
|
||||
MobclickAgent.onEvent(getContext(), "gif_list_redpk_seed", "用户发送红包");
|
||||
ToastUtil.show(getContext().getString(R.string.red_envelope_released_successfully));
|
||||
sendSuccess = true;
|
||||
dismiss();
|
||||
}
|
||||
|
||||
|
@ -1,10 +1,13 @@
|
||||
package com.yunbao.main.activity;
|
||||
|
||||
import android.app.Dialog;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.yunbao.common.activity.AbsActivity;
|
||||
import com.yunbao.common.bean.HttpCallbackModel;
|
||||
import com.yunbao.common.http.HttpCallback;
|
||||
import com.yunbao.common.http.live.LiveNetManager;
|
||||
import com.yunbao.common.utils.DialogUitl;
|
||||
import com.yunbao.common.utils.RouteUtil;
|
||||
import com.yunbao.common.utils.ToastUtil;
|
||||
import com.yunbao.common.utils.WordUtil;
|
||||
@ -25,17 +28,29 @@ public class FeedbackActivity extends AbsActivity {
|
||||
setTitle(WordUtil.getNewString(R.string.activity_feedback_top_title));
|
||||
setTitleBold(true);
|
||||
ViewClicksAntiShake.clicksAntiShake(findViewById(R.id.btn_cs), new ViewClicksAntiShake.ViewClicksCallBack() {
|
||||
Dialog loading;
|
||||
@Override
|
||||
public void onViewClicks() {
|
||||
//TODO 客服
|
||||
loading= DialogUitl.loadingDialog(mContext);
|
||||
loading.show();
|
||||
MainHttpUtil.getCustomerService(new HttpCallback() {
|
||||
@Override
|
||||
public void onSuccess(int code, String msg, String[] info) {
|
||||
loading.dismiss();
|
||||
loading=null;
|
||||
if (info.length == 1) {
|
||||
String url = info[0];
|
||||
RouteUtil.forwardCustomerService(url);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError() {
|
||||
super.onError();
|
||||
loading.dismiss();
|
||||
loading=null;
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
@ -4,6 +4,7 @@ import android.app.Dialog;
|
||||
import android.graphics.Color;
|
||||
import android.text.Editable;
|
||||
import android.text.InputFilter;
|
||||
import android.text.Spanned;
|
||||
import android.text.TextWatcher;
|
||||
import android.util.SparseArray;
|
||||
import android.view.View;
|
||||
@ -32,6 +33,8 @@ import com.yunbao.main.R;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.Locale;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
@Route(path = RouteUtil.PATH_FEEDBACK_EDIT_ACTIVITY)
|
||||
public class FeedbackEditActivity extends AbsActivity {
|
||||
@ -58,8 +61,20 @@ public class FeedbackEditActivity extends AbsActivity {
|
||||
setTitleBold(true);
|
||||
initView();
|
||||
imageUtil = new ProcessImageUtil(this);
|
||||
feedbackEdit.setFilters(new InputFilter[]{new InputFilter.LengthFilter(500)});
|
||||
ciEdit.setFilters(new InputFilter[]{new InputFilter.LengthFilter(30)});
|
||||
feedbackEdit.setFilters(new InputFilter[]{new InputFilter.LengthFilter(501)});
|
||||
ciEdit.setFilters(new InputFilter[]{new InputFilter.LengthFilter(30), new InputFilter() {
|
||||
@Override
|
||||
public CharSequence filter(CharSequence charSequence, int i, int i1, Spanned spanned, int i2, int i3) {
|
||||
/* String regex = "[A-Za-z0-9]+"; // 正则表达式
|
||||
Pattern pattern = Pattern.compile(regex);
|
||||
Matcher matcher = pattern.matcher(charSequence.toString());
|
||||
if (matcher.matches()) {
|
||||
return null;
|
||||
}
|
||||
return "";*/
|
||||
return null;
|
||||
}
|
||||
}});
|
||||
feedbackEdit.addTextChangedListener(new TextWatcher() {
|
||||
@Override
|
||||
public void beforeTextChanged(CharSequence charSequence, int i, int i1, int i2) {
|
||||
@ -68,18 +83,22 @@ public class FeedbackEditActivity extends AbsActivity {
|
||||
|
||||
@Override
|
||||
public void onTextChanged(CharSequence charSequence, int i, int i1, int i2) {
|
||||
if (charSequence.length() == 500) {
|
||||
ToastUtil.show(R.string.activity_feedback_edit_submit_tip2);
|
||||
if (charSequence.length() >= 500) {
|
||||
editNumber.setTextColor(Color.parseColor("#FF5656"));
|
||||
} else {
|
||||
editNumber.setTextColor(Color.parseColor("#333333"));
|
||||
}
|
||||
|
||||
editNumber.setText(String.format(Locale.getDefault(), "%d", charSequence.length()));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterTextChanged(Editable editable) {
|
||||
|
||||
if (editable.length() > 500) {
|
||||
ToastUtil.show(R.string.activity_feedback_edit_submit_tip2);
|
||||
feedbackEdit.setText(editable.toString().substring(0, 500));
|
||||
feedbackEdit.setSelection(feedbackEdit.getText().length());
|
||||
}
|
||||
}
|
||||
});
|
||||
ViewClicksAntiShake.clicksAntiShake(img1, () -> {
|
||||
@ -122,13 +141,13 @@ public class FeedbackEditActivity extends AbsActivity {
|
||||
}
|
||||
JSONArray images = new JSONArray();
|
||||
if (img1.getTag() != null) {
|
||||
images.add((String) img1.getTag());
|
||||
images.add(((String) img1.getTag()).replace("https://downs.yaoulive.com/" ,""));
|
||||
}
|
||||
if (img2.getTag() != null) {
|
||||
images.add((String) img2.getTag());
|
||||
images.add(((String) img2.getTag()).replace("https://downs.yaoulive.com/" ,""));
|
||||
}
|
||||
if (img3.getTag() != null) {
|
||||
images.add((String) img3.getTag());
|
||||
images.add(((String) img3.getTag()).replace("https://downs.yaoulive.com/" ,""));
|
||||
}
|
||||
LiveNetManager.get(mContext)
|
||||
.feedback(feedbackEdit.getText().toString(),
|
||||
@ -150,15 +169,15 @@ public class FeedbackEditActivity extends AbsActivity {
|
||||
|
||||
});
|
||||
img1.setOnLongClickListener(view -> {
|
||||
ToastUtil.show("1");
|
||||
ToastUtil.showDebug("1");
|
||||
return true;
|
||||
});
|
||||
img2.setOnLongClickListener(view -> {
|
||||
ToastUtil.show("2");
|
||||
ToastUtil.showDebug("2");
|
||||
return true;
|
||||
});
|
||||
img3.setOnLongClickListener(view -> {
|
||||
ToastUtil.show("3");
|
||||
ToastUtil.showDebug("3");
|
||||
return true;
|
||||
});
|
||||
imageUtil.setImageResultCallback(new ImageResultCallback() {
|
||||
@ -166,7 +185,7 @@ public class FeedbackEditActivity extends AbsActivity {
|
||||
|
||||
@Override
|
||||
public void onSuccess(File file) {
|
||||
ToastUtil.show("图片地址:" + file.getAbsolutePath());
|
||||
ToastUtil.showDebug("图片地址:" + file.getAbsolutePath());
|
||||
onSuccessToQiNiuUrl(mContext, file, new OnItemClickListener<String>() {
|
||||
@Override
|
||||
public void onItemClick(String bean, int position) {
|
||||
@ -271,9 +290,22 @@ public class FeedbackEditActivity extends AbsActivity {
|
||||
loadingDialog.dismiss();
|
||||
loadingDialog = null;
|
||||
}
|
||||
SparseArray<String> array = new SparseArray<>();
|
||||
array.put(1, WordUtil.getNewString(R.string.activity_feedback_edit_img_select));
|
||||
array.put(2, WordUtil.getNewString(R.string.activity_feedback_edit_img_camera));
|
||||
DialogUitl.showStringArrayDialog(mContext, array, new DialogUitl.StringArrayDialogCallback() {
|
||||
@Override
|
||||
public void onItemClick(String text, int tag) {
|
||||
loadingDialog = DialogUitl.loadingDialog(mContext);
|
||||
loadingDialog.show();
|
||||
if (tag == 1) {
|
||||
imageUtil.getImageByAlumb(false);
|
||||
} else {
|
||||
imageUtil.getImageByCamera(false);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
private void deleteImage(int index) {
|
||||
|
@ -316,15 +316,16 @@ public class SettingActivity extends AbsActivity implements OnItemClickListener<
|
||||
.show();
|
||||
}
|
||||
|
||||
}else if(bean.getId()==17){
|
||||
} else if (bean.getId() == 17 || bean.getId() == 26) {
|
||||
RouteUtil.forwardActivity(RouteUtil.PATH_FEEDBACK_ACTIVITY);
|
||||
}
|
||||
} else {
|
||||
if (bean.getId() == 17) {//意见反馈要在url上加版本号和设备号
|
||||
if (bean.getId() == 17 || bean.getId() == 26) {//意见反馈要在url上加版本号和设备号
|
||||
href += "&version=" + android.os.Build.VERSION.RELEASE + "&model=" + android.os.Build.MODEL;
|
||||
}
|
||||
// WebViewActivity.forward(mContext, href,false);
|
||||
RouteUtil.forwardActivity(RouteUtil.PATH_FEEDBACK_ACTIVITY);
|
||||
} else {
|
||||
WebViewActivity.forward(mContext, href, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -510,7 +510,7 @@ public class MainMeViewHolder extends AbsMainViewHolder implements OnItemClickLi
|
||||
if (bean.getId() == 24) {
|
||||
MobclickAgent.onEvent(mContext, "my_pack", "个人中心点包裹");
|
||||
}
|
||||
if (bean.getId() == 17) {
|
||||
if (bean.getId() == 17 || bean.getId() == 26) {
|
||||
RouteUtil.forwardActivity(RouteUtil.PATH_FEEDBACK_ACTIVITY);
|
||||
} else
|
||||
WebViewActivity.forward(mContext, url, false);
|
||||
|
@ -53,6 +53,7 @@
|
||||
android:layout_width="165dp"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1"
|
||||
android:textAllCaps="false"
|
||||
android:background="#F7F7F7"
|
||||
android:text="@string/activity_feedback_feedback"
|
||||
android:textColor="#333333"
|
||||
|
@ -239,7 +239,13 @@
|
||||
android:layout_marginBottom="130dp"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="*"
|
||||
android:textColor="#FF5656"
|
||||
android:textSize="11sp" />
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
@ -248,13 +254,6 @@
|
||||
android:textColor="#777777"
|
||||
android:textSize="11sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="*"
|
||||
android:textColor="#FF5656"
|
||||
android:textSize="11sp" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
@ -39,4 +39,6 @@
|
||||
<string name="activity_feedback_edit_submit_tip1">請描述您的問題</string>
|
||||
<string name="activity_feedback_edit_submit_tip2">超過字數要求</string>
|
||||
<string name="activity_feedback_edit_submit_tip3">今日反饋次數已用完</string>
|
||||
<string name="activity_feedback_edit_img_select">從相冊選取</string>
|
||||
<string name="activity_feedback_edit_img_camera">拍照</string>
|
||||
</resources>
|
@ -39,4 +39,6 @@
|
||||
<string name="activity_feedback_edit_submit_tip1">Please describe your problem</string>
|
||||
<string name="activity_feedback_edit_submit_tip2">Exceeding the word count requirement</string>
|
||||
<string name="activity_feedback_edit_submit_tip3">Today\'s feedback count has been used up</string>
|
||||
<string name="activity_feedback_edit_img_select">Select from album</string>
|
||||
<string name="activity_feedback_edit_img_camera">Photo shoot</string>
|
||||
</resources>
|
||||
|
Loading…
Reference in New Issue
Block a user