version:3.8
fix:修复报错 update:优化闹钟响铃
This commit is contained in:
@@ -16,8 +16,10 @@ import com.tencent.android.tpush.XGPushClickedResult;
|
||||
import com.tencent.android.tpush.XGPushRegisterResult;
|
||||
import com.tencent.android.tpush.XGPushShowedResult;
|
||||
import com.tencent.android.tpush.XGPushTextMessage;
|
||||
import com.uiui.aios.service.main.MainService;
|
||||
import com.uiui.aios.tpush.common.NotificationService;
|
||||
import com.uiui.aios.tpush.po.XGNotification;
|
||||
import com.uiui.aios.utils.ToastUtil;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
@@ -29,6 +31,7 @@ public class MessageReceiver extends XGPushBaseReceiver {
|
||||
public static final String TEST_ACTION = "com.qq.xgdemo.activity.TEST_ACTION";
|
||||
public static final String LogTag = "xg.test";
|
||||
|
||||
public static final String SET_ALARMCLOCK = "zuoyeos.action.change.alarmclaock";
|
||||
|
||||
private Context mContext;
|
||||
private ContentResolver mResolver;
|
||||
@@ -286,9 +289,8 @@ public class MessageReceiver extends XGPushBaseReceiver {
|
||||
// Toast.makeText(context, text, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
||||
private int changeNum(int paramInt) {
|
||||
return paramInt == 0 ? 1 : 0;
|
||||
}
|
||||
//闹钟
|
||||
private static final String JIGUANG_ALARM_CLOCK = "57";
|
||||
|
||||
private void processCustomMessage(Context context, XGPushTextMessage message) {
|
||||
if (context == null || message == null) {
|
||||
@@ -305,9 +307,12 @@ public class MessageReceiver extends XGPushBaseReceiver {
|
||||
}
|
||||
|
||||
switch (title) {
|
||||
case JIGUANG_ALARM_CLOCK:
|
||||
ToastUtil.betaShow("收到推送消息: 设置闹钟");
|
||||
Intent intent = new Intent(SET_ALARMCLOCK);
|
||||
mContext.sendBroadcast(intent);
|
||||
break;
|
||||
default:
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user