Start with personal profile settings
This commit is contained in:
parent
32f884e547
commit
4e6d012a7d
21 changed files with 360 additions and 20 deletions
|
@ -47,6 +47,8 @@ DISTFILES += qml/harbour-fernschreiber.qml \
|
||||||
qml/components/DocumentPreview.qml \
|
qml/components/DocumentPreview.qml \
|
||||||
qml/components/GamePreview.qml \
|
qml/components/GamePreview.qml \
|
||||||
qml/components/ImagePreview.qml \
|
qml/components/ImagePreview.qml \
|
||||||
|
qml/components/InformationEditArea.qml \
|
||||||
|
qml/components/InformationTextItem.qml \
|
||||||
qml/components/InReplyToRow.qml \
|
qml/components/InReplyToRow.qml \
|
||||||
qml/components/InlineQuery.qml \
|
qml/components/InlineQuery.qml \
|
||||||
qml/components/LocationPreview.qml \
|
qml/components/LocationPreview.qml \
|
||||||
|
@ -64,7 +66,6 @@ DISTFILES += qml/harbour-fernschreiber.qml \
|
||||||
qml/components/TDLibImage.qml \
|
qml/components/TDLibImage.qml \
|
||||||
qml/components/TDLibThumbnail.qml \
|
qml/components/TDLibThumbnail.qml \
|
||||||
qml/components/VoiceNoteOverlay.qml \
|
qml/components/VoiceNoteOverlay.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationEditArea.qml \
|
|
||||||
qml/components/chatInformationPage/ChatInformationPageContent.qml \
|
qml/components/chatInformationPage/ChatInformationPageContent.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationProfilePicture.qml \
|
qml/components/chatInformationPage/ChatInformationProfilePicture.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationProfilePictureList.qml \
|
qml/components/chatInformationPage/ChatInformationProfilePictureList.qml \
|
||||||
|
@ -73,7 +74,6 @@ DISTFILES += qml/harbour-fernschreiber.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationTabItemMembersGroups.qml \
|
qml/components/chatInformationPage/ChatInformationTabItemMembersGroups.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationTabItemSettings.qml \
|
qml/components/chatInformationPage/ChatInformationTabItemSettings.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationTabView.qml \
|
qml/components/chatInformationPage/ChatInformationTabView.qml \
|
||||||
qml/components/chatInformationPage/ChatInformationTextItem.qml \
|
|
||||||
qml/components/chatInformationPage/EditGroupChatPermissionsColumn.qml \
|
qml/components/chatInformationPage/EditGroupChatPermissionsColumn.qml \
|
||||||
qml/components/chatInformationPage/EditSuperGroupSlowModeColumn.qml \
|
qml/components/chatInformationPage/EditSuperGroupSlowModeColumn.qml \
|
||||||
qml/components/inlineQueryResults/InlineQueryResult.qml \
|
qml/components/inlineQueryResults/InlineQueryResult.qml \
|
||||||
|
|
|
@ -18,7 +18,7 @@ PhotoTextsListItem {
|
||||||
// chat title
|
// chat title
|
||||||
primaryText.text: title ? Emoji.emojify(title, Theme.fontSizeMedium) : qsTr("Unknown")
|
primaryText.text: title ? Emoji.emojify(title, Theme.fontSizeMedium) : qsTr("Unknown")
|
||||||
// last user
|
// last user
|
||||||
prologSecondaryText.text: showDraft ? "<i>"+qsTr("Draft")+"</i>" : (is_channel ? "" : ( last_message_sender_id ? ( last_message_sender_id !== ownUserId ? Emoji.emojify(Functions.getUserName(tdLibWrapper.getUserInformation(last_message_sender_id)), primaryText.font.pixelSize) : qsTr("You") ) : "" ))
|
prologSecondaryText.text: showDraft ? "<i>"+qsTr("Draft")+"</i>" : (is_channel ? "" : ( last_message_sender_id ? ( last_message_sender_id !== ownUserId ? Emoji.emojify(Functions.getUserName(tdLibWrapper.getUserInformation(last_message_sender_id)), Theme.fontSizeExtraSmall) : qsTr("You") ) : "" ))
|
||||||
// last message
|
// last message
|
||||||
secondaryText.text: previewText ? Emoji.emojify(Functions.enhanceHtmlEntities(previewText), Theme.fontSizeExtraSmall) : "<i>" + qsTr("No message in this chat.") + "</i>"
|
secondaryText.text: previewText ? Emoji.emojify(Functions.enhanceHtmlEntities(previewText), Theme.fontSizeExtraSmall) : "<i>" + qsTr("No message in this chat.") + "</i>"
|
||||||
// message date
|
// message date
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2020 Sebastian J. Wolf and other contributors
|
Copyright (C) 2020-21 Sebastian J. Wolf and other contributors
|
||||||
|
|
||||||
This file is part of Fernschreiber.
|
This file is part of Fernschreiber.
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
||||||
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License
|
||||||
along with Fernschreiber. If not, see <http://www.gnu.org/licenses/>.
|
along with Fernschreiber. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import QtQuick 2.6
|
import QtQuick 2.6
|
||||||
import Sailfish.Silica 1.0
|
import Sailfish.Silica 1.0
|
||||||
|
|
||||||
|
@ -27,6 +28,7 @@ Column {
|
||||||
property string emptyPlaceholderText
|
property string emptyPlaceholderText
|
||||||
property string text
|
property string text
|
||||||
property bool multiLine
|
property bool multiLine
|
||||||
|
property bool headerLeftAligned
|
||||||
|
|
||||||
property bool isEditing
|
property bool isEditing
|
||||||
property Item editItem: multiLine ? editAreaTextArea : editAreaTextField
|
property Item editItem: multiLine ? editAreaTextArea : editAreaTextField
|
||||||
|
@ -41,6 +43,7 @@ Column {
|
||||||
id: editAreaHeader
|
id: editAreaHeader
|
||||||
height: parent.visible && text !== "" ? Theme.itemSizeExtraSmall : 0
|
height: parent.visible && text !== "" ? Theme.itemSizeExtraSmall : 0
|
||||||
x: 0
|
x: 0
|
||||||
|
horizontalAlignment: headerLeftAligned ? Text.AlignLeft : Text.AlignRight
|
||||||
}
|
}
|
||||||
Row {
|
Row {
|
||||||
id: editAreaTextRow
|
id: editAreaTextRow
|
||||||
|
@ -50,25 +53,30 @@ Column {
|
||||||
id: editAreaTextArea
|
id: editAreaTextArea
|
||||||
visible: editAreaColumn.isEditing && editAreaColumn.multiLine
|
visible: editAreaColumn.isEditing && editAreaColumn.multiLine
|
||||||
width: parent.width - editAreaButton.width
|
width: parent.width - editAreaButton.width
|
||||||
|
textLeftMargin: 0
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
font.pixelSize: Theme.fontSizeSmall
|
||||||
}
|
}
|
||||||
TextField {
|
TextField {
|
||||||
id: editAreaTextField
|
id: editAreaTextField
|
||||||
visible: editAreaColumn.isEditing && !editAreaColumn.multiLine
|
visible: editAreaColumn.isEditing && !editAreaColumn.multiLine
|
||||||
width: parent.width - editAreaButton.width
|
width: parent.width - editAreaButton.width
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
textLeftMargin: 0
|
||||||
EnterKey.onClicked: {
|
EnterKey.onClicked: {
|
||||||
editAreaColumn.isEditing = false;
|
editAreaColumn.isEditing = false;
|
||||||
editAreaColumn.saveButtonClicked(editAreaColumn.editItem.text);
|
editAreaColumn.saveButtonClicked(editAreaColumn.editItem.text);
|
||||||
}
|
}
|
||||||
EnterKey.iconSource: editAreaButton.icon.source
|
EnterKey.iconSource: editAreaButton.icon.source
|
||||||
|
font.pixelSize: Theme.fontSizeSmall
|
||||||
}
|
}
|
||||||
ChatInformationTextItem {
|
InformationTextItem {
|
||||||
id: editAreaTextItem
|
id: editAreaTextItem
|
||||||
visible: !editAreaColumn.isEditing
|
visible: !editAreaColumn.isEditing
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
text: editAreaColumn.text || editAreaColumn.emptyPlaceholderText
|
text: editAreaColumn.text || editAreaColumn.emptyPlaceholderText
|
||||||
width: parent.width - editAreaButton.width
|
width: parent.width - editAreaButton.width
|
||||||
|
height: !editAreaColumn.multiLine ? implicitHeight : editAreaTextField.height
|
||||||
}
|
}
|
||||||
IconButton {
|
IconButton {
|
||||||
id: editAreaButton
|
id: editAreaButton
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2020 Sebastian J. Wolf and other contributors
|
Copyright (C) 2020-21 Sebastian J. Wolf and other contributors
|
||||||
|
|
||||||
This file is part of Fernschreiber.
|
This file is part of Fernschreiber.
|
||||||
|
|
||||||
|
@ -16,11 +16,12 @@
|
||||||
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License
|
||||||
along with Fernschreiber. If not, see <http://www.gnu.org/licenses/>.
|
along with Fernschreiber. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import QtQuick 2.6
|
import QtQuick 2.6
|
||||||
import Sailfish.Silica 1.0
|
import Sailfish.Silica 1.0
|
||||||
|
|
||||||
import "../../js/twemoji.js" as Emoji
|
import "../js/twemoji.js" as Emoji
|
||||||
import "../../js/functions.js" as Functions
|
import "../js/functions.js" as Functions
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
id: textItem
|
id: textItem
|
|
@ -186,11 +186,11 @@ ListItem {
|
||||||
}
|
}
|
||||||
|
|
||||||
onMyMessageChanged: {
|
onMyMessageChanged: {
|
||||||
Debug.log("[ChatModel] This message was updated, index", messageIndex, ", updating content...")
|
Debug.log("[ChatModel] This message was updated, index", messageIndex, ", updating content...");
|
||||||
messageDateText.text = getMessageStatusText(myMessage, messageIndex, chatView.lastReadSentIndex, messageDateText.useElapsed)
|
messageDateText.text = getMessageStatusText(myMessage, messageIndex, chatView.lastReadSentIndex, messageDateText.useElapsed);
|
||||||
messageText.text = Emoji.emojify(Functions.getMessageText(myMessage, false, page.myUserId, false), messageText.font.pixelSize)
|
messageText.text = Emoji.emojify(Functions.getMessageText(myMessage, false, page.myUserId, false), Theme.fontSizeSmall);
|
||||||
if (webPagePreviewLoader.item) {
|
if (webPagePreviewLoader.item) {
|
||||||
webPagePreviewLoader.item.webPageData = myMessage.content.web_page
|
webPagePreviewLoader.item.webPageData = myMessage.content.web_page;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -399,7 +399,7 @@ ListItem {
|
||||||
Text {
|
Text {
|
||||||
id: messageText
|
id: messageText
|
||||||
width: parent.width
|
width: parent.width
|
||||||
text: Emoji.emojify(Functions.getMessageText(myMessage, false, page.myUserId, false), font.pixelSize)
|
text: Emoji.emojify(Functions.getMessageText(myMessage, false, page.myUserId, false), Theme.fontSizeMedium)
|
||||||
font.pixelSize: Theme.fontSizeSmall
|
font.pixelSize: Theme.fontSizeSmall
|
||||||
color: messageListItem.textColor
|
color: messageListItem.textColor
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
|
|
|
@ -350,7 +350,7 @@ SilicaFlickable {
|
||||||
height: imageContainer.hasImage ? imageContainer.maxDimension : 0
|
height: imageContainer.hasImage ? imageContainer.maxDimension : 0
|
||||||
}
|
}
|
||||||
|
|
||||||
ChatInformationEditArea {
|
InformationEditArea {
|
||||||
visible: canEdit
|
visible: canEdit
|
||||||
canEdit: !(chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) && chatInformationPage.groupInformation.status && (chatInformationPage.groupInformation.status.can_change_info || chatInformationPage.groupInformation.status["@type"] === "chatMemberStatusCreator")
|
canEdit: !(chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) && chatInformationPage.groupInformation.status && (chatInformationPage.groupInformation.status.can_change_info || chatInformationPage.groupInformation.status["@type"] === "chatMemberStatusCreator")
|
||||||
headerText: qsTr("Chat Title", "group title header")
|
headerText: qsTr("Chat Title", "group title header")
|
||||||
|
@ -376,7 +376,7 @@ SilicaFlickable {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ChatInformationEditArea {
|
InformationEditArea {
|
||||||
canEdit: ((chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) && chatInformationPage.privateChatUserInformation.id === chatInformationPage.myUserId) || ((chatInformationPage.isBasicGroup || chatInformationPage.isSuperGroup) && chatInformationPage.groupInformation && (chatInformationPage.groupInformation.status.can_change_info || chatInformationPage.groupInformation.status["@type"] === "chatMemberStatusCreator"))
|
canEdit: ((chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) && chatInformationPage.privateChatUserInformation.id === chatInformationPage.myUserId) || ((chatInformationPage.isBasicGroup || chatInformationPage.isSuperGroup) && chatInformationPage.groupInformation && (chatInformationPage.groupInformation.status.can_change_info || chatInformationPage.groupInformation.status["@type"] === "chatMemberStatusCreator"))
|
||||||
emptyPlaceholderText: qsTr("There is no information text available, yet.")
|
emptyPlaceholderText: qsTr("There is no information text available, yet.")
|
||||||
headerText: qsTr("Info", "group or user infotext header")
|
headerText: qsTr("Info", "group or user infotext header")
|
||||||
|
@ -391,7 +391,7 @@ SilicaFlickable {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ChatInformationTextItem {
|
InformationTextItem {
|
||||||
headerText: qsTr("Phone Number", "user phone number header")
|
headerText: qsTr("Phone Number", "user phone number header")
|
||||||
text: ((chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) && chatInformationPage.privateChatUserInformation.phone_number ? "+"+chatInformationPage.privateChatUserInformation.phone_number : "") || ""
|
text: ((chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) && chatInformationPage.privateChatUserInformation.phone_number ? "+"+chatInformationPage.privateChatUserInformation.phone_number : "") || ""
|
||||||
isLinkedLabel: true
|
isLinkedLabel: true
|
||||||
|
@ -408,7 +408,7 @@ SilicaFlickable {
|
||||||
Row {
|
Row {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
visible: !!inviteLinkItem.text
|
visible: !!inviteLinkItem.text
|
||||||
ChatInformationTextItem {
|
InformationTextItem {
|
||||||
id: inviteLinkItem
|
id: inviteLinkItem
|
||||||
text: !(chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) ? chatInformationPage.groupFullInformation.invite_link : ""
|
text: !(chatInformationPage.isPrivateChat || chatInformationPage.isSecretChat) ? chatInformationPage.groupFullInformation.invite_link : ""
|
||||||
width: parent.width - inviteLinkButton.width
|
width: parent.width - inviteLinkButton.width
|
||||||
|
|
|
@ -38,18 +38,18 @@ ChatInformationTabItemBase {
|
||||||
width: tabBase.width - Theme.horizontalPageMargin * 2
|
width: tabBase.width - Theme.horizontalPageMargin * 2
|
||||||
x: Theme.horizontalPageMargin
|
x: Theme.horizontalPageMargin
|
||||||
|
|
||||||
ChatInformationTextItem {
|
InformationTextItem {
|
||||||
headerText: "chatInformation"
|
headerText: "chatInformation"
|
||||||
text:chatInformationPage.chatInformation ? JSON.stringify(chatInformationPage.chatInformation, null, 2) : ""
|
text:chatInformationPage.chatInformation ? JSON.stringify(chatInformationPage.chatInformation, null, 2) : ""
|
||||||
isLinkedLabel: true
|
isLinkedLabel: true
|
||||||
}
|
}
|
||||||
ChatInformationTextItem {
|
InformationTextItem {
|
||||||
headerText: "groupInformation"
|
headerText: "groupInformation"
|
||||||
text: chatInformationPage.groupInformation ? JSON.stringify(chatInformationPage.groupInformation, null, 2) : ""
|
text: chatInformationPage.groupInformation ? JSON.stringify(chatInformationPage.groupInformation, null, 2) : ""
|
||||||
isLinkedLabel: true
|
isLinkedLabel: true
|
||||||
}
|
}
|
||||||
|
|
||||||
ChatInformationTextItem {
|
InformationTextItem {
|
||||||
headerText: "groupFullInformation"
|
headerText: "groupFullInformation"
|
||||||
text: chatInformationPage.groupFullInformation ? JSON.stringify(chatInformationPage.groupFullInformation, null, 2) : ""
|
text: chatInformationPage.groupFullInformation ? JSON.stringify(chatInformationPage.groupFullInformation, null, 2) : ""
|
||||||
isLinkedLabel: true
|
isLinkedLabel: true
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
import QtQuick 2.6
|
import QtQuick 2.6
|
||||||
import Sailfish.Silica 1.0
|
import Sailfish.Silica 1.0
|
||||||
import WerkWolf.Fernschreiber 1.0
|
import WerkWolf.Fernschreiber 1.0
|
||||||
|
import "../components"
|
||||||
import "../js/functions.js" as Functions
|
import "../js/functions.js" as Functions
|
||||||
|
|
||||||
Page {
|
Page {
|
||||||
|
@ -27,6 +28,14 @@ Page {
|
||||||
|
|
||||||
readonly property bool landscapeLayout: (width > height && Screen.sizeCategory > Screen.Small) || Screen.sizeCategory > Screen.Medium
|
readonly property bool landscapeLayout: (width > height && Screen.sizeCategory > Screen.Small) || Screen.sizeCategory > Screen.Medium
|
||||||
|
|
||||||
|
Connections {
|
||||||
|
target: tdLibWrapper
|
||||||
|
onOwnUserUpdated: {
|
||||||
|
firstNameEditArea.text = userInformation.first_name;
|
||||||
|
lastNameEditArea.text = userInformation.last_name;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
SilicaFlickable {
|
SilicaFlickable {
|
||||||
id: settingsContainer
|
id: settingsContainer
|
||||||
contentHeight: column.height
|
contentHeight: column.height
|
||||||
|
@ -40,6 +49,72 @@ Page {
|
||||||
title: qsTr("Settings")
|
title: qsTr("Settings")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SectionHeader {
|
||||||
|
text: qsTr("User Profile")
|
||||||
|
}
|
||||||
|
|
||||||
|
InformationEditArea {
|
||||||
|
id: firstNameEditArea
|
||||||
|
visible: true
|
||||||
|
canEdit: true
|
||||||
|
headerText: qsTr("First Name", "first name of the logged-in profile - header")
|
||||||
|
text: tdLibWrapper.getUserInformation().first_name
|
||||||
|
width: parent.width - ( 2 * Theme.horizontalPageMargin )
|
||||||
|
headerLeftAligned: true
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
|
||||||
|
onSaveButtonClicked: {
|
||||||
|
if(!editItem.errorHighlight) {
|
||||||
|
tdLibWrapper.setName(textValue, lastNameEditArea.text);
|
||||||
|
} else {
|
||||||
|
isEditing = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
onTextEdited: {
|
||||||
|
if(textValue.length > 0 && textValue.length < 65) {
|
||||||
|
editItem.errorHighlight = false;
|
||||||
|
editItem.label = "";
|
||||||
|
editItem.placeholderText = "";
|
||||||
|
} else {
|
||||||
|
editItem.label = qsTr("Enter 1-64 characters");
|
||||||
|
editItem.placeholderText = editItem.label;
|
||||||
|
editItem.errorHighlight = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
InformationEditArea {
|
||||||
|
id: lastNameEditArea
|
||||||
|
visible: true
|
||||||
|
canEdit: true
|
||||||
|
headerText: qsTr("Last Name", "last name of the logged-in profile - header")
|
||||||
|
text: tdLibWrapper.getUserInformation().last_name
|
||||||
|
width: parent.width - ( 2 * Theme.horizontalPageMargin )
|
||||||
|
headerLeftAligned: true
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
|
||||||
|
onSaveButtonClicked: {
|
||||||
|
if(!editItem.errorHighlight) {
|
||||||
|
tdLibWrapper.setName(firstNameEditArea.text, textValue);
|
||||||
|
} else {
|
||||||
|
isEditing = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
onTextEdited: {
|
||||||
|
if(textValue.length >= 0 && textValue.length < 65) {
|
||||||
|
editItem.errorHighlight = false;
|
||||||
|
editItem.label = "";
|
||||||
|
editItem.placeholderText = "";
|
||||||
|
} else {
|
||||||
|
editItem.label = qsTr("Enter 0-64 characters");
|
||||||
|
editItem.placeholderText = editItem.label;
|
||||||
|
editItem.errorHighlight = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
SectionHeader {
|
SectionHeader {
|
||||||
text: qsTr("Behavior")
|
text: qsTr("Behavior")
|
||||||
}
|
}
|
||||||
|
|
|
@ -1177,6 +1177,17 @@ void TDLibWrapper::deleteFile(int fileId)
|
||||||
this->sendRequest(requestObject);
|
this->sendRequest(requestObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void TDLibWrapper::setName(const QString &firstName, const QString &lastName)
|
||||||
|
{
|
||||||
|
LOG("Set name of current user" << firstName << lastName);
|
||||||
|
QVariantMap requestObject;
|
||||||
|
requestObject.insert(_TYPE, "setName");
|
||||||
|
requestObject.insert("first_name", firstName);
|
||||||
|
requestObject.insert("last_name", lastName);
|
||||||
|
|
||||||
|
this->sendRequest(requestObject);
|
||||||
|
}
|
||||||
|
|
||||||
void TDLibWrapper::searchEmoji(const QString &queryString)
|
void TDLibWrapper::searchEmoji(const QString &queryString)
|
||||||
{
|
{
|
||||||
LOG("Searching emoji" << queryString);
|
LOG("Searching emoji" << queryString);
|
||||||
|
@ -1431,6 +1442,7 @@ void TDLibWrapper::handleUserUpdated(const QVariantMap &userInformation)
|
||||||
if (updatedUserId == this->options.value("my_id").toString()) {
|
if (updatedUserId == this->options.value("my_id").toString()) {
|
||||||
LOG("Own user information updated :)");
|
LOG("Own user information updated :)");
|
||||||
this->userInformation = userInformation;
|
this->userInformation = userInformation;
|
||||||
|
emit ownUserUpdated(userInformation);
|
||||||
}
|
}
|
||||||
LOG("User information updated:" << userInformation.value(USERNAME).toString() << userInformation.value(FIRST_NAME).toString() << userInformation.value(LAST_NAME).toString());
|
LOG("User information updated:" << userInformation.value(USERNAME).toString() << userInformation.value(FIRST_NAME).toString() << userInformation.value(LAST_NAME).toString());
|
||||||
this->allUsers.insert(updatedUserId, userInformation);
|
this->allUsers.insert(updatedUserId, userInformation);
|
||||||
|
|
|
@ -196,6 +196,7 @@ public:
|
||||||
Q_INVOKABLE void cancelDownloadFile(int fileId);
|
Q_INVOKABLE void cancelDownloadFile(int fileId);
|
||||||
Q_INVOKABLE void cancelUploadFile(int fileId);
|
Q_INVOKABLE void cancelUploadFile(int fileId);
|
||||||
Q_INVOKABLE void deleteFile(int fileId);
|
Q_INVOKABLE void deleteFile(int fileId);
|
||||||
|
Q_INVOKABLE void setName(const QString &firstName, const QString &lastName);
|
||||||
|
|
||||||
// Others (candidates for extraction ;))
|
// Others (candidates for extraction ;))
|
||||||
Q_INVOKABLE void searchEmoji(const QString &queryString);
|
Q_INVOKABLE void searchEmoji(const QString &queryString);
|
||||||
|
@ -224,6 +225,7 @@ signals:
|
||||||
void chatReadInboxUpdated(const QString &chatId, const QString &lastReadInboxMessageId, int unreadCount);
|
void chatReadInboxUpdated(const QString &chatId, const QString &lastReadInboxMessageId, int unreadCount);
|
||||||
void chatReadOutboxUpdated(const QString &chatId, const QString &lastReadOutboxMessageId);
|
void chatReadOutboxUpdated(const QString &chatId, const QString &lastReadOutboxMessageId);
|
||||||
void userUpdated(const QString &userId, const QVariantMap &userInformation);
|
void userUpdated(const QString &userId, const QVariantMap &userInformation);
|
||||||
|
void ownUserUpdated(const QVariantMap &userInformation);
|
||||||
void basicGroupUpdated(qlonglong groupId);
|
void basicGroupUpdated(qlonglong groupId);
|
||||||
void superGroupUpdated(qlonglong groupId);
|
void superGroupUpdated(qlonglong groupId);
|
||||||
void chatOnlineMemberCountUpdated(const QString &chatId, int onlineMemberCount);
|
void chatOnlineMemberCountUpdated(const QString &chatId, int onlineMemberCount);
|
||||||
|
|
|
@ -1508,6 +1508,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation>Einige Inline-Bots fragen bei Nutzung Standortdaten an</translation>
|
<translation>Einige Inline-Bots fragen bei Nutzung Standortdaten an</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Geben Sie 1-128 Zeichen ein {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Geben Sie 1-128 Zeichen ein {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1508,6 +1508,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation>Some inline bots request location data when using them</translation>
|
<translation>Some inline bots request location data when using them</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Enter 1-128 characters {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Enter 1-128 characters {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1508,6 +1508,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Marcar caracteres 1-128 {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Marcar caracteres 1-128 {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1509,6 +1509,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Syötä 1-128 merkkiä {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Syötä 1-128 merkkiä {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1483,6 +1483,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1508,6 +1508,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Inserisci da 1 a 128 caratteri {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Inserisci da 1 a 128 caratteri {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1533,6 +1533,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Wprowadź znaki 1-128 {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Wprowadź znaki 1-128 {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1533,6 +1533,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Введите 1-128 символов {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Введите 1-128 символов {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1508,6 +1508,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Ange 1-128 tecken {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Ange 1-128 tecken {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1483,6 +1483,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation>使用某些内联机器人时会请求位置数据</translation>
|
<translation>使用某些内联机器人时会请求位置数据</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">输入 1-128 个字符 {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">输入 1-128 个字符 {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
|
@ -1508,6 +1508,28 @@
|
||||||
<source>Some inline bots request location data when using them</source>
|
<source>Some inline bots request location data when using them</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>User Profile</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>First Name</source>
|
||||||
|
<comment>first name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 1-64 characters</source>
|
||||||
|
<translation type="unfinished">Enter 1-128 characters {1-64 ?}</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Last Name</source>
|
||||||
|
<comment>last name of the logged-in profile - header</comment>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Enter 0-64 characters</source>
|
||||||
|
<translation type="unfinished">Enter 1-128 characters {0-64 ?}</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>StickerPicker</name>
|
<name>StickerPicker</name>
|
||||||
|
|
Loading…
Reference in a new issue