From 7c3debc00c4e4adff388d1894b107f6c9120f68d Mon Sep 17 00:00:00 2001 From: Him188 <Him188@mamoe.net> Date: Thu, 20 Feb 2020 17:16:46 +0800 Subject: [PATCH] Fix GroupMessage subscribing --- .../net.mamoe.mirai/data/EventPacket.kt | 19 ------------------- .../net.mamoe.mirai/message/MessagePacket.kt | 4 ++-- 2 files changed, 2 insertions(+), 21 deletions(-) delete mode 100644 mirai-core/src/commonMain/kotlin/net.mamoe.mirai/data/EventPacket.kt diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/data/EventPacket.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/data/EventPacket.kt deleted file mode 100644 index 630db03e1..000000000 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/data/EventPacket.kt +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Copyright 2020 Mamoe Technologies and contributors. - * - * 此源代码的使用受 GNU AFFERO GENERAL PUBLIC LICENSE version 3 许可证的约束, 可以在以下链接找到该许可证. - * Use of this source code is governed by the GNU AGPLv3 license that can be found through the following link. - * - * https://github.com/mamoe/mirai/blob/master/LICENSE - */ - -package net.mamoe.mirai.data - -import net.mamoe.mirai.event.Event - -/** - * 事件包. 可被监听. - * - * @see Event - */ -interface EventPacket : Event, Packet \ No newline at end of file diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/MessagePacket.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/MessagePacket.kt index 6e53d8032..a42a778fc 100644 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/MessagePacket.kt +++ b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/MessagePacket.kt @@ -19,7 +19,7 @@ import net.mamoe.mirai.contact.Contact import net.mamoe.mirai.contact.Group import net.mamoe.mirai.contact.Member import net.mamoe.mirai.contact.QQ -import net.mamoe.mirai.data.EventPacket +import net.mamoe.mirai.data.Packet import net.mamoe.mirai.event.events.BotEvent import net.mamoe.mirai.message.data.* import net.mamoe.mirai.utils.* @@ -37,7 +37,7 @@ expect abstract class MessagePacket<TSender : QQ, TSubject : Contact>(bot: Bot) */ // Tips: 在 IntelliJ 中 (左侧边栏) 打开 `Structure`, 可查看类结构 @Suppress("NOTHING_TO_INLINE") @MiraiInternalAPI -abstract class MessagePacketBase<TSender : QQ, TSubject : Contact>(_bot: Bot) : EventPacket, BotEvent { +abstract class MessagePacketBase<TSender : QQ, TSubject : Contact>(_bot: Bot) : Packet, BotEvent { /** * 接受到这条消息的 */