mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2024-11-25 19:48:43 +00:00
rename all thumb* usages
This commit is contained in:
parent
e7b21dcd3d
commit
90b9c66bea
@ -332,9 +332,17 @@ const val stickerFileIdField = "sticker_file_id"
|
|||||||
|
|
||||||
const val gameShortNameField = "game_short_name"
|
const val gameShortNameField = "game_short_name"
|
||||||
|
|
||||||
|
const val thumbnailUrlField = "thumbnail_url"
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailUrlField", "dev.inmo.tgbotapi.types.thumbnailUrlField"))
|
||||||
const val thumbUrlField = "thumb_url"
|
const val thumbUrlField = "thumb_url"
|
||||||
|
const val thumbnailMimeTypeField = "thumbnail_mime_type"
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailMimeTypeField", "dev.inmo.tgbotapi.types.thumbnailMimeTypeField"))
|
||||||
const val thumbMimeTypeField = "thumb_mime_type"
|
const val thumbMimeTypeField = "thumb_mime_type"
|
||||||
|
const val thumbnailWidthField = "thumbnail_width"
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailWidthField", "dev.inmo.tgbotapi.types.thumbnailWidthField"))
|
||||||
const val thumbWidthField = "thumb_width"
|
const val thumbWidthField = "thumb_width"
|
||||||
|
const val thumbnailHeightField = "thumbnail_height"
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailHeightField", "dev.inmo.tgbotapi.types.thumbnailHeightField"))
|
||||||
const val thumbHeightField = "thumb_height"
|
const val thumbHeightField = "thumb_height"
|
||||||
|
|
||||||
const val inputMessageContentField = "input_message_content"
|
const val inputMessageContentField = "input_message_content"
|
||||||
|
@ -23,12 +23,12 @@ class InlineQueryResultArticle(
|
|||||||
val hideUrl: Boolean? = null,
|
val hideUrl: Boolean? = null,
|
||||||
@SerialName(descriptionField)
|
@SerialName(descriptionField)
|
||||||
override val description: String? = null,
|
override val description: String? = null,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String? = null,
|
override val thumbnailUrl: String? = null,
|
||||||
@SerialName(thumbWidthField)
|
@SerialName(thumbnailWidthField)
|
||||||
override val thumbWidth: Int? = null,
|
override val thumbnailWidth: Int? = null,
|
||||||
@SerialName(thumbHeightField)
|
@SerialName(thumbnailHeightField)
|
||||||
override val thumbHeight: Int? = null
|
override val thumbnailHeight: Int? = null
|
||||||
) : InlineQueryResult,
|
) : InlineQueryResult,
|
||||||
ThumbSizedInlineQueryResult,
|
ThumbSizedInlineQueryResult,
|
||||||
TitledInlineQueryResult,
|
TitledInlineQueryResult,
|
||||||
|
@ -20,12 +20,12 @@ data class InlineQueryResultContact(
|
|||||||
override val lastName: String? = null,
|
override val lastName: String? = null,
|
||||||
@SerialName(vcardField)
|
@SerialName(vcardField)
|
||||||
override val vcard: String? = null,
|
override val vcard: String? = null,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String? = null,
|
override val thumbnailUrl: String? = null,
|
||||||
@SerialName(thumbWidthField)
|
@SerialName(thumbnailWidthField)
|
||||||
override val thumbWidth: Int? = null,
|
override val thumbnailWidth: Int? = null,
|
||||||
@SerialName(thumbHeightField)
|
@SerialName(thumbnailHeightField)
|
||||||
override val thumbHeight: Int? = null,
|
override val thumbnailHeight: Int? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: InlineKeyboardMarkup? = null,
|
override val replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
@SerialName(inputMessageContentField)
|
@SerialName(inputMessageContentField)
|
||||||
|
@ -21,24 +21,24 @@ fun InlineQueryResultDocumentImpl(
|
|||||||
url: String,
|
url: String,
|
||||||
title: String,
|
title: String,
|
||||||
mimeType: MimeType,
|
mimeType: MimeType,
|
||||||
thumbUrl: String? = null,
|
thumbnailUrl: String? = null,
|
||||||
thumbWidth: Int? = null,
|
thumbnailWidth: Int? = null,
|
||||||
thumbHeight: Int? = null,
|
thumbnailHeight: Int? = null,
|
||||||
description: String? = null,
|
description: String? = null,
|
||||||
text: String? = null,
|
text: String? = null,
|
||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultDocumentImpl(id, url, title, mimeType, thumbUrl, thumbWidth, thumbHeight, description, text, parseMode, null, replyMarkup, inputMessageContent)
|
) = InlineQueryResultDocumentImpl(id, url, title, mimeType, thumbnailUrl, thumbnailWidth, thumbnailHeight, description, text, parseMode, null, replyMarkup, inputMessageContent)
|
||||||
|
|
||||||
fun InlineQueryResultDocumentImpl(
|
fun InlineQueryResultDocumentImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
title: String,
|
title: String,
|
||||||
mimeType: MimeType,
|
mimeType: MimeType,
|
||||||
thumbUrl: String? = null,
|
thumbnailUrl: String? = null,
|
||||||
thumbWidth: Int? = null,
|
thumbnailWidth: Int? = null,
|
||||||
thumbHeight: Int? = null,
|
thumbnailHeight: Int? = null,
|
||||||
description: String? = null,
|
description: String? = null,
|
||||||
entities: TextSourcesList,
|
entities: TextSourcesList,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
@ -48,9 +48,9 @@ fun InlineQueryResultDocumentImpl(
|
|||||||
url,
|
url,
|
||||||
title,
|
title,
|
||||||
mimeType,
|
mimeType,
|
||||||
thumbUrl,
|
thumbnailUrl,
|
||||||
thumbWidth,
|
thumbnailWidth,
|
||||||
thumbHeight,
|
thumbnailHeight,
|
||||||
description,
|
description,
|
||||||
entities.makeString(),
|
entities.makeString(),
|
||||||
null,
|
null,
|
||||||
@ -69,12 +69,12 @@ data class InlineQueryResultDocumentImpl internal constructor(
|
|||||||
override val title: String,
|
override val title: String,
|
||||||
@SerialName(mimeTypeField)
|
@SerialName(mimeTypeField)
|
||||||
override val mimeType: MimeType,
|
override val mimeType: MimeType,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String? = null,
|
override val thumbnailUrl: String? = null,
|
||||||
@SerialName(thumbWidthField)
|
@SerialName(thumbnailWidthField)
|
||||||
override val thumbWidth: Int? = null,
|
override val thumbnailWidth: Int? = null,
|
||||||
@SerialName(thumbHeightField)
|
@SerialName(thumbnailHeightField)
|
||||||
override val thumbHeight: Int? = null,
|
override val thumbnailHeight: Int? = null,
|
||||||
@SerialName(descriptionField)
|
@SerialName(descriptionField)
|
||||||
override val description: String? = null,
|
override val description: String? = null,
|
||||||
@SerialName(captionField)
|
@SerialName(captionField)
|
||||||
|
@ -20,8 +20,8 @@ import kotlinx.serialization.Serializable
|
|||||||
fun InlineQueryResultGifImpl(
|
fun InlineQueryResultGifImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
thumbMimeType: MimeType? = null,
|
thumbnailMimeType: MimeType? = null,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
duration: Int? = null,
|
duration: Int? = null,
|
||||||
@ -30,13 +30,13 @@ fun InlineQueryResultGifImpl(
|
|||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultGifImpl(id, url, thumbUrl, thumbMimeType, width, height, duration, title, text, parseMode, null, replyMarkup, inputMessageContent)
|
) = InlineQueryResultGifImpl(id, url, thumbnailUrl, thumbnailMimeType, width, height, duration, title, text, parseMode, null, replyMarkup, inputMessageContent)
|
||||||
|
|
||||||
fun InlineQueryResultGifImpl(
|
fun InlineQueryResultGifImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
thumbMimeType: MimeType? = null,
|
thumbnailMimeType: MimeType? = null,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
duration: Int? = null,
|
duration: Int? = null,
|
||||||
@ -47,8 +47,8 @@ fun InlineQueryResultGifImpl(
|
|||||||
) = InlineQueryResultGifImpl(
|
) = InlineQueryResultGifImpl(
|
||||||
id,
|
id,
|
||||||
url,
|
url,
|
||||||
thumbUrl,
|
thumbnailUrl,
|
||||||
thumbMimeType,
|
thumbnailMimeType,
|
||||||
width,
|
width,
|
||||||
height,
|
height,
|
||||||
duration,
|
duration,
|
||||||
@ -63,8 +63,8 @@ fun InlineQueryResultGifImpl(
|
|||||||
fun InlineQueryResultGifImpl(
|
fun InlineQueryResultGifImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
gifFile: FileId,
|
gifFile: FileId,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
thumbMimeType: MimeType? = null,
|
thumbnailMimeType: MimeType? = null,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
duration: Int? = null,
|
duration: Int? = null,
|
||||||
@ -73,13 +73,13 @@ fun InlineQueryResultGifImpl(
|
|||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultGifImpl(id, gifFile.fileId, thumbUrl, thumbMimeType, width, height, duration, title, text, parseMode, replyMarkup, inputMessageContent)
|
) = InlineQueryResultGifImpl(id, gifFile.fileId, thumbnailUrl, thumbnailMimeType, width, height, duration, title, text, parseMode, replyMarkup, inputMessageContent)
|
||||||
|
|
||||||
fun InlineQueryResultGifImpl(
|
fun InlineQueryResultGifImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
gifFile: FileId,
|
gifFile: FileId,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
thumbMimeType: MimeType? = null,
|
thumbnailMimeType: MimeType? = null,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
duration: Int? = null,
|
duration: Int? = null,
|
||||||
@ -88,7 +88,7 @@ fun InlineQueryResultGifImpl(
|
|||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultGifImpl(
|
) = InlineQueryResultGifImpl(
|
||||||
id, gifFile.fileId, thumbUrl, thumbMimeType, width, height, duration, title, entities, replyMarkup, inputMessageContent
|
id, gifFile.fileId, thumbnailUrl, thumbnailMimeType, width, height, duration, title, entities, replyMarkup, inputMessageContent
|
||||||
)
|
)
|
||||||
|
|
||||||
@Serializable
|
@Serializable
|
||||||
@ -97,10 +97,10 @@ data class InlineQueryResultGifImpl internal constructor(
|
|||||||
override val id: InlineQueryIdentifier,
|
override val id: InlineQueryIdentifier,
|
||||||
@SerialName(gifUrlField)
|
@SerialName(gifUrlField)
|
||||||
override val url: String,
|
override val url: String,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String,
|
override val thumbnailUrl: String,
|
||||||
@SerialName(thumbMimeTypeField)
|
@SerialName(thumbnailMimeTypeField)
|
||||||
override val thumbMimeType: MimeType? = null,
|
override val thumbnailMimeType: MimeType? = null,
|
||||||
@SerialName(gifWidthField)
|
@SerialName(gifWidthField)
|
||||||
override val width: Int? = null,
|
override val width: Int? = null,
|
||||||
@SerialName(gifHeightField)
|
@SerialName(gifHeightField)
|
||||||
@ -126,8 +126,8 @@ data class InlineQueryResultGifImpl internal constructor(
|
|||||||
}
|
}
|
||||||
|
|
||||||
init {
|
init {
|
||||||
if (thumbMimeType != null && thumbMimeType !in telegramInlineModeGifPermittedMimeTypes) {
|
if (thumbnailMimeType != null && thumbnailMimeType !in telegramInlineModeGifPermittedMimeTypes) {
|
||||||
error("Passed thumb mime type is not permitted in Telegram Bot API. Passed $thumbMimeType, but permitted $telegramInlineModeGifPermittedMimeTypes")
|
error("Passed thumb mime type is not permitted in Telegram Bot API. Passed $thumbnailMimeType, but permitted $telegramInlineModeGifPermittedMimeTypes")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,12 +26,12 @@ data class InlineQueryResultLocation(
|
|||||||
override val heading: Degrees? = null,
|
override val heading: Degrees? = null,
|
||||||
@SerialName(proximityAlertRadiusField)
|
@SerialName(proximityAlertRadiusField)
|
||||||
override val proximityAlertRadius: Meters? = null,
|
override val proximityAlertRadius: Meters? = null,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String? = null,
|
override val thumbnailUrl: String? = null,
|
||||||
@SerialName(thumbWidthField)
|
@SerialName(thumbnailWidthField)
|
||||||
override val thumbWidth: Int? = null,
|
override val thumbnailWidth: Int? = null,
|
||||||
@SerialName(thumbHeightField)
|
@SerialName(thumbnailHeightField)
|
||||||
override val thumbHeight: Int? = null,
|
override val thumbnailHeight: Int? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: InlineKeyboardMarkup? = null,
|
override val replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
@SerialName(inputMessageContentField)
|
@SerialName(inputMessageContentField)
|
||||||
|
@ -19,8 +19,8 @@ import kotlinx.serialization.Serializable
|
|||||||
fun InlineQueryResultMpeg4GifImpl(
|
fun InlineQueryResultMpeg4GifImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
thumbMimeType: MimeType? = null,
|
thumbnailMimeType: MimeType? = null,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
duration: Int? = null,
|
duration: Int? = null,
|
||||||
@ -29,13 +29,13 @@ fun InlineQueryResultMpeg4GifImpl(
|
|||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultMpeg4GifImpl(id, url, thumbUrl, thumbMimeType, width, height, duration, title, text, parseMode, null, replyMarkup, inputMessageContent)
|
) = InlineQueryResultMpeg4GifImpl(id, url, thumbnailUrl, thumbnailMimeType, width, height, duration, title, text, parseMode, null, replyMarkup, inputMessageContent)
|
||||||
|
|
||||||
fun InlineQueryResultMpeg4GifImpl(
|
fun InlineQueryResultMpeg4GifImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
thumbMimeType: MimeType? = null,
|
thumbnailMimeType: MimeType? = null,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
duration: Int? = null,
|
duration: Int? = null,
|
||||||
@ -46,8 +46,8 @@ fun InlineQueryResultMpeg4GifImpl(
|
|||||||
) = InlineQueryResultMpeg4GifImpl(
|
) = InlineQueryResultMpeg4GifImpl(
|
||||||
id,
|
id,
|
||||||
url,
|
url,
|
||||||
thumbUrl,
|
thumbnailUrl,
|
||||||
thumbMimeType,
|
thumbnailMimeType,
|
||||||
width,
|
width,
|
||||||
height,
|
height,
|
||||||
duration,
|
duration,
|
||||||
@ -65,10 +65,10 @@ data class InlineQueryResultMpeg4GifImpl internal constructor(
|
|||||||
override val id: InlineQueryIdentifier,
|
override val id: InlineQueryIdentifier,
|
||||||
@SerialName(mpeg4GifUrlField)
|
@SerialName(mpeg4GifUrlField)
|
||||||
override val url: String,
|
override val url: String,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String,
|
override val thumbnailUrl: String,
|
||||||
@SerialName(thumbMimeTypeField)
|
@SerialName(thumbnailMimeTypeField)
|
||||||
override val thumbMimeType: MimeType? = null,
|
override val thumbnailMimeType: MimeType? = null,
|
||||||
@SerialName(mpeg4GifWidthField)
|
@SerialName(mpeg4GifWidthField)
|
||||||
override val width: Int? = null,
|
override val width: Int? = null,
|
||||||
@SerialName(mpeg4GifHeightField)
|
@SerialName(mpeg4GifHeightField)
|
||||||
@ -94,8 +94,8 @@ data class InlineQueryResultMpeg4GifImpl internal constructor(
|
|||||||
}
|
}
|
||||||
|
|
||||||
init {
|
init {
|
||||||
if (thumbMimeType != null && thumbMimeType !in telegramInlineModeGifPermittedMimeTypes) {
|
if (thumbnailMimeType != null && thumbnailMimeType !in telegramInlineModeGifPermittedMimeTypes) {
|
||||||
error("Passed thumb mime type is not permitted in Telegram Bot API. Passed $thumbMimeType, but permitted $telegramInlineModeGifPermittedMimeTypes")
|
error("Passed thumb mime type is not permitted in Telegram Bot API. Passed $thumbnailMimeType, but permitted $telegramInlineModeGifPermittedMimeTypes")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -18,7 +18,7 @@ import kotlinx.serialization.Serializable
|
|||||||
fun InlineQueryResultPhotoImpl(
|
fun InlineQueryResultPhotoImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
title: String? = null,
|
title: String? = null,
|
||||||
@ -27,12 +27,12 @@ fun InlineQueryResultPhotoImpl(
|
|||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultPhotoImpl(id, url, thumbUrl, width, height, title, description, text, parseMode, null, replyMarkup, inputMessageContent)
|
) = InlineQueryResultPhotoImpl(id, url, thumbnailUrl, width, height, title, description, text, parseMode, null, replyMarkup, inputMessageContent)
|
||||||
|
|
||||||
fun InlineQueryResultPhotoImpl(
|
fun InlineQueryResultPhotoImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
height: Int? = null,
|
height: Int? = null,
|
||||||
title: String? = null,
|
title: String? = null,
|
||||||
@ -43,7 +43,7 @@ fun InlineQueryResultPhotoImpl(
|
|||||||
) = InlineQueryResultPhotoImpl(
|
) = InlineQueryResultPhotoImpl(
|
||||||
id,
|
id,
|
||||||
url,
|
url,
|
||||||
thumbUrl,
|
thumbnailUrl,
|
||||||
width,
|
width,
|
||||||
height,
|
height,
|
||||||
title,
|
title,
|
||||||
@ -61,8 +61,8 @@ data class InlineQueryResultPhotoImpl internal constructor(
|
|||||||
override val id: InlineQueryIdentifier,
|
override val id: InlineQueryIdentifier,
|
||||||
@SerialName(photoUrlField)
|
@SerialName(photoUrlField)
|
||||||
override val url: String,
|
override val url: String,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String,
|
override val thumbnailUrl: String,
|
||||||
@SerialName(photoWidthField)
|
@SerialName(photoWidthField)
|
||||||
override val width: Int? = null,
|
override val width: Int? = null,
|
||||||
@SerialName(photoHeightField)
|
@SerialName(photoHeightField)
|
||||||
|
@ -29,12 +29,12 @@ data class InlineQueryResultVenue(
|
|||||||
override val googlePlaceId: GooglePlaceId? = null,
|
override val googlePlaceId: GooglePlaceId? = null,
|
||||||
@SerialName(googlePlaceTypeField)
|
@SerialName(googlePlaceTypeField)
|
||||||
override val googlePlaceType: GooglePlaceType? = null,
|
override val googlePlaceType: GooglePlaceType? = null,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String? = null,
|
override val thumbnailUrl: String? = null,
|
||||||
@SerialName(thumbWidthField)
|
@SerialName(thumbnailWidthField)
|
||||||
override val thumbWidth: Int? = null,
|
override val thumbnailWidth: Int? = null,
|
||||||
@SerialName(thumbHeightField)
|
@SerialName(thumbnailHeightField)
|
||||||
override val thumbHeight: Int? = null,
|
override val thumbnailHeight: Int? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: InlineKeyboardMarkup? = null,
|
override val replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
@SerialName(inputMessageContentField)
|
@SerialName(inputMessageContentField)
|
||||||
|
@ -19,7 +19,7 @@ import kotlinx.serialization.Serializable
|
|||||||
fun InlineQueryResultVideoImpl(
|
fun InlineQueryResultVideoImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
mimeType: MimeType,
|
mimeType: MimeType,
|
||||||
title: String,
|
title: String,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
@ -30,12 +30,12 @@ fun InlineQueryResultVideoImpl(
|
|||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
replyMarkup: InlineKeyboardMarkup? = null,
|
replyMarkup: InlineKeyboardMarkup? = null,
|
||||||
inputMessageContent: InputMessageContent? = null
|
inputMessageContent: InputMessageContent? = null
|
||||||
) = InlineQueryResultVideoImpl(id, url, thumbUrl, mimeType, title, width, height, duration, description, text, parseMode, null, replyMarkup, inputMessageContent)
|
) = InlineQueryResultVideoImpl(id, url, thumbnailUrl, mimeType, title, width, height, duration, description, text, parseMode, null, replyMarkup, inputMessageContent)
|
||||||
|
|
||||||
fun InlineQueryResultVideoImpl(
|
fun InlineQueryResultVideoImpl(
|
||||||
id: InlineQueryIdentifier,
|
id: InlineQueryIdentifier,
|
||||||
url: String,
|
url: String,
|
||||||
thumbUrl: String,
|
thumbnailUrl: String,
|
||||||
mimeType: MimeType,
|
mimeType: MimeType,
|
||||||
title: String,
|
title: String,
|
||||||
width: Int? = null,
|
width: Int? = null,
|
||||||
@ -48,7 +48,7 @@ fun InlineQueryResultVideoImpl(
|
|||||||
) = InlineQueryResultVideoImpl(
|
) = InlineQueryResultVideoImpl(
|
||||||
id,
|
id,
|
||||||
url,
|
url,
|
||||||
thumbUrl,
|
thumbnailUrl,
|
||||||
mimeType,
|
mimeType,
|
||||||
title,
|
title,
|
||||||
width,
|
width,
|
||||||
@ -68,8 +68,8 @@ data class InlineQueryResultVideoImpl internal constructor(
|
|||||||
override val id: InlineQueryIdentifier,
|
override val id: InlineQueryIdentifier,
|
||||||
@SerialName(videoUrlField)
|
@SerialName(videoUrlField)
|
||||||
override val url: String,
|
override val url: String,
|
||||||
@SerialName(thumbUrlField)
|
@SerialName(thumbnailUrlField)
|
||||||
override val thumbUrl: String,
|
override val thumbnailUrl: String,
|
||||||
@SerialName(mimeTypeField)
|
@SerialName(mimeTypeField)
|
||||||
override val mimeType: MimeType,
|
override val mimeType: MimeType,
|
||||||
@SerialName(titleField)
|
@SerialName(titleField)
|
||||||
|
@ -1,6 +1,12 @@
|
|||||||
package dev.inmo.tgbotapi.types.InlineQueries.InlineQueryResult.abstracts
|
package dev.inmo.tgbotapi.types.InlineQueries.InlineQueryResult.abstracts
|
||||||
|
|
||||||
interface ThumbSizedInlineQueryResult : InlineQueryResult, ThumbedInlineQueryResult {
|
interface ThumbSizedInlineQueryResult : InlineQueryResult, ThumbedInlineQueryResult {
|
||||||
|
val thumbnailWidth: Int?
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailWidth"))
|
||||||
val thumbWidth: Int?
|
val thumbWidth: Int?
|
||||||
|
get() = thumbnailWidth
|
||||||
|
val thumbnailHeight: Int?
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailHeight"))
|
||||||
val thumbHeight: Int?
|
val thumbHeight: Int?
|
||||||
|
get() = thumbnailHeight
|
||||||
}
|
}
|
@ -3,9 +3,15 @@ package dev.inmo.tgbotapi.types.InlineQueries.InlineQueryResult.abstracts
|
|||||||
import dev.inmo.tgbotapi.utils.MimeType
|
import dev.inmo.tgbotapi.utils.MimeType
|
||||||
|
|
||||||
interface ThumbedInlineQueryResult : InlineQueryResult {
|
interface ThumbedInlineQueryResult : InlineQueryResult {
|
||||||
|
val thumbnailUrl: String?
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailUrl"))
|
||||||
val thumbUrl: String?
|
val thumbUrl: String?
|
||||||
|
get() = thumbnailUrl
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ThumbedWithMimeTypeInlineQueryResult : ThumbedInlineQueryResult {
|
interface ThumbedWithMimeTypeInlineQueryResult : ThumbedInlineQueryResult {
|
||||||
|
val thumbnailMimeType: MimeType?
|
||||||
|
@Deprecated("Renamed in telegram bot api", ReplaceWith("thumbnailMimeType"))
|
||||||
val thumbMimeType: MimeType?
|
val thumbMimeType: MimeType?
|
||||||
|
get() = thumbnailMimeType
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user