chore: update to nim 2.0 (#16472)

This commit is contained in:
richΛrd 2025-01-07 13:46:57 -04:00 committed by GitHub
parent 13cdaa6ac7
commit d7420bbab2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
60 changed files with 158 additions and 147 deletions

5
.gitmodules vendored
View File

@ -114,3 +114,8 @@
[submodule "vendor/qzxing"] [submodule "vendor/qzxing"]
path = vendor/qzxing path = vendor/qzxing
url = https://github.com/status-im/qzxing.git url = https://github.com/status-im/qzxing.git
[submodule "vendor/checksums"]
path = vendor/checksums
url = https://github.com/nim-lang/checksums.git
ignore = untracked
branch = master

View File

@ -571,6 +571,7 @@ $(NIM_STATUS_CLIENT): NIM_PARAMS += $(RESOURCES_LAYOUT)
$(NIM_STATUS_CLIENT): $(NIM_SOURCES) | statusq dotherside check-qt-dir $(STATUSGO) $(STATUSKEYCARDGO) $(QRCODEGEN) $(FLEETS) rcc compile-translations deps $(NIM_STATUS_CLIENT): $(NIM_SOURCES) | statusq dotherside check-qt-dir $(STATUSGO) $(STATUSKEYCARDGO) $(QRCODEGEN) $(FLEETS) rcc compile-translations deps
echo -e $(BUILD_MSG) "$@" echo -e $(BUILD_MSG) "$@"
$(ENV_SCRIPT) nim c $(NIM_PARAMS) \ $(ENV_SCRIPT) nim c $(NIM_PARAMS) \
--mm:refc \
--passL:"-L$(STATUSGO_LIBDIR)" \ --passL:"-L$(STATUSGO_LIBDIR)" \
--passL:"-lstatus" \ --passL:"-lstatus" \
--passL:"-L$(STATUSQ_INSTALL_PATH)/StatusQ" \ --passL:"-L$(STATUSQ_INSTALL_PATH)/StatusQ" \
@ -866,7 +867,7 @@ NIM_TESTS := $(foreach test_file,$(NIM_TEST_FILES),nim-test-run/$(test_file))
nim-test-run/%: | dotherside $(STATUSGO) nim-test-run/%: | dotherside $(STATUSGO)
LD_LIBRARY_PATH="$(QT5_LIBDIR)":"$(STATUSGO_LIBDIR)":"$(LD_LIBRARY_PATH)" $(ENV_SCRIPT) \ LD_LIBRARY_PATH="$(QT5_LIBDIR)":"$(STATUSGO_LIBDIR)":"$(LD_LIBRARY_PATH)" $(ENV_SCRIPT) \
nim c $(NIM_PARAMS) $(NIM_EXTRA_PARAMS) --passL:"-L$(STATUSGO_LIBDIR)" --passL:"-lstatus" -r $(subst nim-test-run/,,$@) nim c $(NIM_PARAMS) $(NIM_EXTRA_PARAMS) --mm:refc --passL:"-L$(STATUSGO_LIBDIR)" --passL:"-lstatus" -r $(subst nim-test-run/,,$@)
tests-nim-linux: $(NIM_TESTS) tests-nim-linux: $(NIM_TESTS)

View File

@ -14,12 +14,12 @@ type
WorkerThreadArg* = object # of RootObj WorkerThreadArg* = object # of RootObj
chanSendToMain*: AsyncChannel[ThreadSafeString] chanSendToMain*: AsyncChannel[ThreadSafeString]
chanRecvFromMain*: AsyncChannel[ThreadSafeString] chanRecvFromMain*: AsyncChannel[ThreadSafeString]
vptr*: ByteAddress vptr*: uint
MarathonWorker* = ref object of RootObj MarathonWorker* = ref object of RootObj
chanSendToWorker*: AsyncChannel[ThreadSafeString] chanSendToWorker*: AsyncChannel[ThreadSafeString]
chanRecvFromWorker*: AsyncChannel[ThreadSafeString] chanRecvFromWorker*: AsyncChannel[ThreadSafeString]
thread*: Thread[WorkerThreadArg] thread*: Thread[WorkerThreadArg]
vptr*: ByteAddress vptr*: uint
method name*(self: MarathonWorker): string {.base.} = method name*(self: MarathonWorker): string {.base.} =
# override this base method # override this base method

View File

@ -6,7 +6,7 @@ import # status-desktop libs
type type
QObjectTaskArg* = ref object of TaskArg QObjectTaskArg* = ref object of TaskArg
vptr*: ByteAddress vptr*: uint
slot*: string slot*: string
proc finish*[T](arg: QObjectTaskArg, payload: T) = proc finish*[T](arg: QObjectTaskArg, payload: T) =

View File

@ -297,7 +297,7 @@ method getDetails*(self: Module, sectionId: string, chatId: string): string =
var chatName = c.name var chatName = c.name
var chatImage = c.icon var chatImage = c.icon
if c.chatType == ChatType.OneToOne: if c.chatType == ChatType.OneToOne:
(chatName, chatImage) = self.controller.getOneToOneChatNameAndImage(c.id) (chatName, chatImage, _) = self.controller.getOneToOneChatNameAndImage(c.id)
jsonObject["cName"] = %* chatName jsonObject["cName"] = %* chatName
jsonObject["cImage"] = %* chatImage jsonObject["cImage"] = %* chatImage

View File

@ -80,7 +80,7 @@ proc getChatSubItems(self: Module, chats: seq[ChatDto], categories: seq[Category
var colorId: int = 0 var colorId: int = 0
let isOneToOneChat = chatDto.chatType == ChatType.OneToOne let isOneToOneChat = chatDto.chatType == ChatType.OneToOne
if isOneToOneChat: if isOneToOneChat:
(chatName, chatImage) = self.controller.getOneToOneChatNameAndImage(chatDto.id) (chatName, chatImage, _) = self.controller.getOneToOneChatNameAndImage(chatDto.id)
colorHash = self.controller.getColorHash(chatDto.id) colorHash = self.controller.getColorHash(chatDto.id)
colorId = self.controller.getColorId(chatDto.id) colorId = self.controller.getColorId(chatDto.id)
elif chatDto.chatType == ChatType.CommunityChat: elif chatDto.chatType == ChatType.CommunityChat:
@ -219,7 +219,7 @@ proc getResultItemFromChats(self: Module, sectionId: string, chats: seq[ChatDto]
var colorId: int = 0 var colorId: int = 0
let isOneToOneChat = chatDto.chatType == ChatType.OneToOne let isOneToOneChat = chatDto.chatType == ChatType.OneToOne
if(isOneToOneChat): if(isOneToOneChat):
(chatName, chatImage) = self.controller.getOneToOneChatNameAndImage(chatDto.id) (chatName, chatImage, _) = self.controller.getOneToOneChatNameAndImage(chatDto.id)
colorHash = self.controller.getColorHash(chatDto.id) colorHash = self.controller.getColorHash(chatDto.id)
colorId = self.controller.getColorId(chatDto.id) colorId = self.controller.getColorId(chatDto.id)
@ -310,7 +310,7 @@ method onSearchMessagesDone*(self: Module, messages: seq[MessageDto]) =
var chatName = chatDto.name var chatName = chatDto.name
var chatImage = chatDto.icon var chatImage = chatDto.icon
if(chatDto.chatType == ChatType.OneToOne): if(chatDto.chatType == ChatType.OneToOne):
(chatName, chatImage) = self.controller.getOneToOneChatNameAndImage(chatDto.id) (chatName, chatImage, _) = self.controller.getOneToOneChatNameAndImage(chatDto.id)
let item = result_item.initItem(m.id, renderedMessageText, $m.timestamp, m.`from`, senderName, let item = result_item.initItem(m.id, renderedMessageText, $m.timestamp, m.`from`, senderName,
SEARCH_RESULT_MESSAGES_SECTION_NAME, senderImage, chatDto.color, chatName, "", chatImage, SEARCH_RESULT_MESSAGES_SECTION_NAME, senderImage, chatDto.color, chatName, "", chatImage,
chatDto.color, false, true, colorId, colorHash) chatDto.color, false, true, colorId, colorHash)

View File

@ -2,7 +2,7 @@ import json
import web3/ethtypes import web3/ethtypes
import types import types
template getProp(obj: JsonNode, prop: string, value: var typedesc[int]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[int]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = obj[prop].getInt value = obj[prop].getInt
@ -10,7 +10,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[int]): bool =
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[int64]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[int64]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = obj[prop].getBiggestInt value = obj[prop].getBiggestInt
@ -18,7 +18,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[int64]): bool
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[uint]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[uint]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = uint(obj[prop].getInt) value = uint(obj[prop].getInt)
@ -26,7 +26,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[uint]): bool =
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[uint64]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[uint64]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = uint64(obj[prop].getBiggestInt) value = uint64(obj[prop].getBiggestInt)
@ -34,7 +34,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[uint64]): bool
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[string]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[string]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop) and obj[prop].kind == JString): if (obj.kind == JObject and obj.contains(prop) and obj[prop].kind == JString):
value = obj[prop].getStr value = obj[prop].getStr
@ -42,7 +42,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[string]): bool
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[float]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[float]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop) and obj[prop].kind == JFloat): if (obj.kind == JObject and obj.contains(prop) and obj[prop].kind == JFloat):
value = obj[prop].getFloat value = obj[prop].getFloat
@ -50,7 +50,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[float]): bool
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[bool]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[bool]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = obj[prop].getBool value = obj[prop].getBool
@ -58,7 +58,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[bool]): bool =
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[JsonNode]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[JsonNode]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = obj[prop] value = obj[prop]
@ -66,7 +66,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[JsonNode]): bo
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[Address]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[Address]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = fromHex(Address, obj[prop].getStr) value = fromHex(Address, obj[prop].getStr)
@ -74,7 +74,7 @@ template getProp(obj: JsonNode, prop: string, value: var typedesc[Address]): boo
success success
template getProp(obj: JsonNode, prop: string, value: var typedesc[MemberRole]): bool = template getProp(obj: JsonNode, prop: string, value: var typedesc[MemberRole]): bool {.redefine.} =
var success = false var success = false
if (obj.kind == JObject and obj.contains(prop)): if (obj.kind == JObject and obj.contains(prop)):
value = MemberRole(obj[prop].getInt) value = MemberRole(obj[prop].getInt)

View File

@ -1,3 +1,5 @@
import "json_serialization"
type type
ContentType* {.pure.} = enum ContentType* {.pure.} = enum
NewMessagesMarker = -3 NewMessagesMarker = -3
@ -93,6 +95,8 @@ type TokenType* {.pure.} = enum
Unknown = 4, Unknown = 4,
ENS = 5 ENS = 5
TokenType.configureJsonSerialization(EnumAsNumber)
type RequestToJoinState* {.pure.} = enum type RequestToJoinState* {.pure.} = enum
None = 0 None = 0
InProgress InProgress

View File

@ -327,7 +327,7 @@ QtObject:
mnemonic: mnemonic, mnemonic: mnemonic,
paths: paths, paths: paths,
tptr: fetchAddressesFromNotImportedMnemonicTask, tptr: fetchAddressesFromNotImportedMnemonicTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAddressesFromNotImportedMnemonicFetched", slot: "onAddressesFromNotImportedMnemonicFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -428,7 +428,7 @@ QtObject:
let arg = TimerTaskArg( let arg = TimerTaskArg(
tptr: timerTask, tptr: timerTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onWaitForReencryptionTimeout", slot: "onWaitForReencryptionTimeout",
timeoutInMilliseconds: timeout timeoutInMilliseconds: timeout
) )
@ -460,7 +460,7 @@ QtObject:
let hashedCurrentPassword = hashPassword(currentPassword) let hashedCurrentPassword = hashPassword(currentPassword)
let arg = ConvertRegularProfileKeypairToKeycardTaskArg( let arg = ConvertRegularProfileKeypairToKeycardTaskArg(
tptr: convertRegularProfileKeypairToKeycardTask, tptr: convertRegularProfileKeypairToKeycardTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onConvertRegularProfileKeypairToKeycard", slot: "onConvertRegularProfileKeypairToKeycard",
accountDataJson: accountDataJson, accountDataJson: accountDataJson,
settingsJson: settingsJson, settingsJson: settingsJson,
@ -490,7 +490,7 @@ QtObject:
let hashedNewPassword = hashPassword(newPassword) let hashedNewPassword = hashPassword(newPassword)
let arg = ConvertKeycardProfileKeypairToRegularTaskArg( let arg = ConvertKeycardProfileKeypairToRegularTaskArg(
tptr: convertKeycardProfileKeypairToRegularTask, tptr: convertKeycardProfileKeypairToRegularTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onConvertKeycardProfileKeypairToRegular", slot: "onConvertKeycardProfileKeypairToRegular",
mnemonic: mnemonic, mnemonic: mnemonic,
currentPassword: currentPassword, currentPassword: currentPassword,

View File

@ -150,7 +150,7 @@ QtObject:
proc asyncActivityNotificationLoad*(self: Service) = proc asyncActivityNotificationLoad*(self: Service) =
let arg = AsyncActivityNotificationLoadTaskArg( let arg = AsyncActivityNotificationLoadTaskArg(
tptr: asyncActivityNotificationLoadTask, tptr: asyncActivityNotificationLoadTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncActivityNotificationLoaded", slot: "asyncActivityNotificationLoaded",
cursor: self.cursor, cursor: self.cursor,
limit: DEFAULT_LIMIT, limit: DEFAULT_LIMIT,

View File

@ -182,7 +182,7 @@ QtObject:
proc asyncGetActiveChats*(self: Service) = proc asyncGetActiveChats*(self: Service) =
let arg = AsyncGetActiveChatsTaskArg( let arg = AsyncGetActiveChatsTaskArg(
tptr: asyncGetActiveChatsTask, tptr: asyncGetActiveChatsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetActiveChatsResponse", slot: "onAsyncGetActiveChatsResponse",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -430,7 +430,7 @@ QtObject:
let arg = AsyncSendImagesTaskArg( let arg = AsyncSendImagesTaskArg(
tptr: asyncSendImagesTask, tptr: asyncSendImagesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSendImagesDone", slot: "onAsyncSendImagesDone",
chatId: chatId, chatId: chatId,
imagePathsAndDataJson: imagePathsAndDataJson, imagePathsAndDataJson: imagePathsAndDataJson,
@ -481,7 +481,7 @@ QtObject:
let arg = AsyncSendMessageTaskArg( let arg = AsyncSendMessageTaskArg(
tptr: asyncSendMessageTask, tptr: asyncSendMessageTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSendMessageDone", slot: "onAsyncSendMessageDone",
chatId: chatId, chatId: chatId,
processedMsg: processedMsg, processedMsg: processedMsg,
@ -728,7 +728,7 @@ QtObject:
proc asyncCheckChannelPermissions*(self: Service, communityId: string, chatId: string) = proc asyncCheckChannelPermissions*(self: Service, communityId: string, chatId: string) =
let arg = AsyncCheckChannelPermissionsTaskArg( let arg = AsyncCheckChannelPermissionsTaskArg(
tptr: asyncCheckChannelPermissionsTask, tptr: asyncCheckChannelPermissionsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCheckChannelPermissionsDone", slot: "onAsyncCheckChannelPermissionsDone",
communityId: communityId, communityId: communityId,
chatId: chatId chatId: chatId
@ -755,7 +755,7 @@ QtObject:
proc asyncCheckAllChannelsPermissions*(self: Service, communityId: string, addresses: seq[string]) = proc asyncCheckAllChannelsPermissions*(self: Service, communityId: string, addresses: seq[string]) =
let arg = AsyncCheckAllChannelsPermissionsTaskArg( let arg = AsyncCheckAllChannelsPermissionsTaskArg(
tptr: asyncCheckAllChannelsPermissionsTask, tptr: asyncCheckAllChannelsPermissionsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCheckAllChannelsPermissionsDone", slot: "onAsyncCheckAllChannelsPermissionsDone",
communityId: communityId, communityId: communityId,
addresses: addresses, addresses: addresses,

View File

@ -801,7 +801,7 @@ QtObject:
try: try:
let arg = AsyncLoadCommunitiesDataTaskArg( let arg = AsyncLoadCommunitiesDataTaskArg(
tptr: asyncLoadCommunitiesDataTask, tptr: asyncLoadCommunitiesDataTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncCommunitiesDataLoaded", slot: "asyncCommunitiesDataLoaded",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -1480,7 +1480,7 @@ QtObject:
proc toggleCollapsedCommunityCategoryAsync*(self: Service, communityId: string, categoryId: string, collapsed: bool) = proc toggleCollapsedCommunityCategoryAsync*(self: Service, communityId: string, categoryId: string, collapsed: bool) =
let arg = AsyncCollapseCategory( let arg = AsyncCollapseCategory(
tptr: asyncCollapseCategoryTask, tptr: asyncCollapseCategoryTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCollapseCategoryDone", slot: "onAsyncCollapseCategoryDone",
communityId: communityId, communityId: communityId,
categoryId: categoryId, categoryId: categoryId,
@ -1635,7 +1635,7 @@ QtObject:
proc asyncCheckPermissionsToJoin*(self: Service, communityId: string, addresses: seq[string]) = proc asyncCheckPermissionsToJoin*(self: Service, communityId: string, addresses: seq[string]) =
let arg = AsyncCheckPermissionsToJoinTaskArg( let arg = AsyncCheckPermissionsToJoinTaskArg(
tptr: asyncCheckPermissionsToJoinTask, tptr: asyncCheckPermissionsToJoinTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCheckPermissionsToJoinDone", slot: "onAsyncCheckPermissionsToJoinDone",
communityId: communityId, communityId: communityId,
addresses: addresses, addresses: addresses,
@ -1711,7 +1711,7 @@ QtObject:
try: try:
let arg = AsyncRequestToJoinCommunityTaskArg( let arg = AsyncRequestToJoinCommunityTaskArg(
tptr: asyncRequestToJoinCommunityTask, tptr: asyncRequestToJoinCommunityTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncRequestToJoinCommunityDone", slot: "onAsyncRequestToJoinCommunityDone",
communityId: communityId, communityId: communityId,
ensName: ensName, ensName: ensName,
@ -1746,7 +1746,7 @@ QtObject:
signatures: seq[string]) = signatures: seq[string]) =
let arg = AsyncEditSharedAddressesTaskArg( let arg = AsyncEditSharedAddressesTaskArg(
tptr: asyncEditSharedAddressesTask, tptr: asyncEditSharedAddressesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncEditSharedAddressesDone", slot: "onAsyncEditSharedAddressesDone",
communityId: communityId, communityId: communityId,
addressesToShare: addressesToShare, addressesToShare: addressesToShare,
@ -1778,7 +1778,7 @@ QtObject:
self.events.emit(SIGNAL_ACCEPT_REQUEST_TO_JOIN_LOADING, CommunityMemberArgs(communityId: communityId, pubKey: userKey)) self.events.emit(SIGNAL_ACCEPT_REQUEST_TO_JOIN_LOADING, CommunityMemberArgs(communityId: communityId, pubKey: userKey))
let arg = AsyncAcceptRequestToJoinCommunityTaskArg( let arg = AsyncAcceptRequestToJoinCommunityTaskArg(
tptr: asyncAcceptRequestToJoinCommunityTask, tptr: asyncAcceptRequestToJoinCommunityTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncAcceptRequestToJoinCommunityDone", slot: "onAsyncAcceptRequestToJoinCommunityDone",
communityId: communityId, communityId: communityId,
requestId: requestId requestId: requestId
@ -1835,7 +1835,7 @@ QtObject:
try: try:
let arg = AsyncLoadCuratedCommunitiesTaskArg( let arg = AsyncLoadCuratedCommunitiesTaskArg(
tptr: asyncLoadCuratedCommunitiesTask, tptr: asyncLoadCuratedCommunitiesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncLoadCuratedCommunitiesDone", slot: "onAsyncLoadCuratedCommunitiesDone",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -1867,7 +1867,7 @@ QtObject:
proc collectCommunityMetricsMessagesTimestamps*(self: Service, communityId: string, intervals: string) = proc collectCommunityMetricsMessagesTimestamps*(self: Service, communityId: string, intervals: string) =
let arg = AsyncCollectCommunityMetricsTaskArg( let arg = AsyncCollectCommunityMetricsTaskArg(
tptr: asyncCollectCommunityMetricsTask, tptr: asyncCollectCommunityMetricsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncCommunityMetricsLoaded", slot: "asyncCommunityMetricsLoaded",
communityId: communityId, communityId: communityId,
metricsType: CommunityMetricsType.MessagesTimestamps, metricsType: CommunityMetricsType.MessagesTimestamps,
@ -1878,7 +1878,7 @@ QtObject:
proc collectCommunityMetricsMessagesCount*(self: Service, communityId: string, intervals: string) = proc collectCommunityMetricsMessagesCount*(self: Service, communityId: string, intervals: string) =
let arg = AsyncCollectCommunityMetricsTaskArg( let arg = AsyncCollectCommunityMetricsTaskArg(
tptr: asyncCollectCommunityMetricsTask, tptr: asyncCollectCommunityMetricsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncCommunityMetricsLoaded", slot: "asyncCommunityMetricsLoaded",
communityId: communityId, communityId: communityId,
metricsType: CommunityMetricsType.MessagesCount, metricsType: CommunityMetricsType.MessagesCount,
@ -1901,7 +1901,7 @@ QtObject:
let arg = AsyncRequestCommunityInfoTaskArg( let arg = AsyncRequestCommunityInfoTaskArg(
tptr: asyncRequestCommunityInfoTask, tptr: asyncRequestCommunityInfoTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncCommunityInfoLoaded", slot: "asyncCommunityInfoLoaded",
communityId: communityId, communityId: communityId,
importing: importing, importing: importing,
@ -2095,7 +2095,7 @@ QtObject:
proc asyncRemoveUserFromCommunity*(self: Service, communityId, pubKey: string) = proc asyncRemoveUserFromCommunity*(self: Service, communityId, pubKey: string) =
let arg = AsyncCommunityMemberActionTaskArg( let arg = AsyncCommunityMemberActionTaskArg(
tptr: asyncRemoveUserFromCommunityTask, tptr: asyncRemoveUserFromCommunityTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCommunityMemberActionCompleted", slot: "onAsyncCommunityMemberActionCompleted",
communityId: communityId, communityId: communityId,
pubKey: pubKey, pubKey: pubKey,
@ -2105,7 +2105,7 @@ QtObject:
proc asyncBanUserFromCommunity*(self: Service, communityId, pubKey: string, deleteAllMessages: bool) = proc asyncBanUserFromCommunity*(self: Service, communityId, pubKey: string, deleteAllMessages: bool) =
let arg = AsyncCommunityMemberActionTaskArg( let arg = AsyncCommunityMemberActionTaskArg(
tptr: asyncBanUserFromCommunityTask, tptr: asyncBanUserFromCommunityTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCommunityMemberActionCompleted", slot: "onAsyncCommunityMemberActionCompleted",
communityId: communityId, communityId: communityId,
pubKey: pubKey, pubKey: pubKey,
@ -2116,7 +2116,7 @@ QtObject:
proc asyncUnbanUserFromCommunity*(self: Service, communityId, pubKey: string) = proc asyncUnbanUserFromCommunity*(self: Service, communityId, pubKey: string) =
let arg = AsyncCommunityMemberActionTaskArg( let arg = AsyncCommunityMemberActionTaskArg(
tptr: asyncUnbanUserFromCommunityTask, tptr: asyncUnbanUserFromCommunityTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncCommunityMemberActionCompleted", slot: "onAsyncCommunityMemberActionCompleted",
communityId: communityId, communityId: communityId,
pubKey: pubKey, pubKey: pubKey,
@ -2306,7 +2306,7 @@ QtObject:
proc asyncGetRevealedAccountsForMember*(self: Service, communityId, memberPubkey: string) = proc asyncGetRevealedAccountsForMember*(self: Service, communityId, memberPubkey: string) =
let arg = AsyncGetRevealedAccountsArg( let arg = AsyncGetRevealedAccountsArg(
tptr: asyncGetRevealedAccountsForMemberTask, tptr: asyncGetRevealedAccountsForMemberTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetRevealedAccountsForMemberCompleted", slot: "onAsyncGetRevealedAccountsForMemberCompleted",
communityId: communityId, communityId: communityId,
memberPubkey: memberPubkey, memberPubkey: memberPubkey,
@ -2337,7 +2337,7 @@ QtObject:
proc asyncGetRevealedAccountsForAllMembers*(self: Service, communityId: string) = proc asyncGetRevealedAccountsForAllMembers*(self: Service, communityId: string) =
let arg = AsyncGetRevealedAccountsArg( let arg = AsyncGetRevealedAccountsArg(
tptr: asyncGetRevealedAccountsForAllMembersTask, tptr: asyncGetRevealedAccountsForAllMembersTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetRevealedAccountsForAllMembersCompleted", slot: "onAsyncGetRevealedAccountsForAllMembersCompleted",
communityId: communityId, communityId: communityId,
) )
@ -2366,7 +2366,7 @@ QtObject:
proc asyncReevaluateCommunityMembersPermissions*(self: Service, communityId: string) = proc asyncReevaluateCommunityMembersPermissions*(self: Service, communityId: string) =
let arg = AsyncGetRevealedAccountsArg( let arg = AsyncGetRevealedAccountsArg(
tptr: asyncReevaluateCommunityMembersPermissionsTask, tptr: asyncReevaluateCommunityMembersPermissionsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncReevaluateCommunityMembersPermissionsCompleted", slot: "onAsyncReevaluateCommunityMembersPermissionsCompleted",
communityId: communityId, communityId: communityId,
) )
@ -2385,7 +2385,7 @@ QtObject:
proc asyncSetCommunityShard*(self: Service, communityId: string, shardIndex: int) = proc asyncSetCommunityShard*(self: Service, communityId: string, shardIndex: int) =
let arg = AsyncSetCommunityShardArg( let arg = AsyncSetCommunityShardArg(
tptr: asyncSetCommunityShardTask, tptr: asyncSetCommunityShardTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSetCommunityShardDone", slot: "onAsyncSetCommunityShardDone",
communityId: communityId, communityId: communityId,
shardIndex: shardIndex, shardIndex: shardIndex,

View File

@ -703,7 +703,7 @@ QtObject:
proc getCommunityTokensDetailsAsync*(self: Service, communityId: string) = proc getCommunityTokensDetailsAsync*(self: Service, communityId: string) =
let arg = GetCommunityTokensDetailsArg( let arg = GetCommunityTokensDetailsArg(
tptr: getCommunityTokensDetailsTaskArg, tptr: getCommunityTokensDetailsTaskArg,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onCommunityTokensDetailsLoaded", slot: "onCommunityTokensDetailsLoaded",
communityId: communityId communityId: communityId
) )
@ -731,7 +731,7 @@ QtObject:
proc getAllCommunityTokensAsync*(self: Service) = proc getAllCommunityTokensAsync*(self: Service) =
let arg = GetAllCommunityTokensArg( let arg = GetAllCommunityTokensArg(
tptr: getAllCommunityTokensTaskArg, tptr: getAllCommunityTokensTaskArg,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onGotAllCommunityTokens", slot: "onGotAllCommunityTokens",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -854,7 +854,7 @@ QtObject:
self.tempTokensAndAmounts = collectiblesAndAmounts self.tempTokensAndAmounts = collectiblesAndAmounts
let arg = AsyncGetMintFees( let arg = AsyncGetMintFees(
tptr: asyncGetMintFeesTask, tptr: asyncGetMintFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAirdropFees", slot: "onAirdropFees",
collectiblesAndAmounts: collectiblesAndAmounts, collectiblesAndAmounts: collectiblesAndAmounts,
walletAddresses: walletAddresses, walletAddresses: walletAddresses,
@ -887,7 +887,7 @@ QtObject:
return return
let arg = AsyncGetDeployFeesArg( let arg = AsyncGetDeployFeesArg(
tptr: asyncGetDeployFeesTask, tptr: asyncGetDeployFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onDeployFees", slot: "onDeployFees",
chainId: chainId, chainId: chainId,
addressFrom: accountAddress, addressFrom: accountAddress,
@ -903,7 +903,7 @@ QtObject:
try: try:
let arg = AsyncSetSignerFeesArg( let arg = AsyncSetSignerFeesArg(
tptr: asyncSetSignerFeesTask, tptr: asyncSetSignerFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onSetSignerFees", slot: "onSetSignerFees",
chainId: chainId, chainId: chainId,
contractAddress: contractAddress, contractAddress: contractAddress,
@ -921,7 +921,7 @@ QtObject:
try: try:
let arg = AsyncDeployOwnerContractsFeesArg( let arg = AsyncDeployOwnerContractsFeesArg(
tptr: asyncGetDeployOwnerContractsFeesTask, tptr: asyncGetDeployOwnerContractsFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onDeployOwnerContractsFees", slot: "onDeployOwnerContractsFees",
chainId: chainId, chainId: chainId,
addressFrom: accountAddress, addressFrom: accountAddress,
@ -994,7 +994,7 @@ QtObject:
return return
let arg = AsyncGetRemoteBurnFees( let arg = AsyncGetRemoteBurnFees(
tptr: asyncGetRemoteBurnFeesTask, tptr: asyncGetRemoteBurnFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onSelfDestructFees", slot: "onSelfDestructFees",
chainId: contract.chainId, chainId: contract.chainId,
contractAddress: contract.address, contractAddress: contract.address,
@ -1072,7 +1072,7 @@ QtObject:
let contract = self.findContractByUniqueId(contractUniqueKey) let contract = self.findContractByUniqueId(contractUniqueKey)
let arg = AsyncGetBurnFees( let arg = AsyncGetBurnFees(
tptr: asyncGetBurnFeesTask, tptr: asyncGetBurnFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onBurnFees", slot: "onBurnFees",
chainId: contract.chainId, chainId: contract.chainId,
contractAddress: contract.address, contractAddress: contract.address,
@ -1268,7 +1268,7 @@ QtObject:
if communityToken.tokenType == TokenType.ERC20: if communityToken.tokenType == TokenType.ERC20:
let arg = FetchAssetOwnersArg( let arg = FetchAssetOwnersArg(
tptr: fetchAssetOwnersTaskArg, tptr: fetchAssetOwnersTaskArg,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onCommunityTokenOwnersFetched", slot: "onCommunityTokenOwnersFetched",
chainId: communityToken.chainId, chainId: communityToken.chainId,
contractAddress: communityToken.address, contractAddress: communityToken.address,
@ -1279,7 +1279,7 @@ QtObject:
elif communityToken.tokenType == TokenType.ERC721: elif communityToken.tokenType == TokenType.ERC721:
let arg = FetchCollectibleOwnersArg( let arg = FetchCollectibleOwnersArg(
tptr: fetchCollectibleOwnersTaskArg, tptr: fetchCollectibleOwnersTaskArg,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onCommunityTokenOwnersFetched", slot: "onCommunityTokenOwnersFetched",
chainId: communityToken.chainId, chainId: communityToken.chainId,
contractAddress: communityToken.address, contractAddress: communityToken.address,
@ -1353,7 +1353,7 @@ QtObject:
proc asyncGetOwnerTokenOwnerAddress*(self: Service, chainId: int, contractAddress: string) = proc asyncGetOwnerTokenOwnerAddress*(self: Service, chainId: int, contractAddress: string) =
let arg = GetOwnerTokenOwnerAddressArgs( let arg = GetOwnerTokenOwnerAddressArgs(
tptr: getOwnerTokenOwnerAddressTask, tptr: getOwnerTokenOwnerAddressTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onGetOwnerTokenOwner", slot: "onGetOwnerTokenOwner",
chainId: chainId, chainId: chainId,
contractAddress: contractAddress contractAddress: contractAddress

View File

@ -142,7 +142,7 @@ QtObject:
proc fetchContacts*(self: Service) = proc fetchContacts*(self: Service) =
let arg = AsyncFetchContactsTaskArg( let arg = AsyncFetchContactsTaskArg(
tptr: asyncFetchContactsTask, tptr: asyncFetchContactsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "fetchContactsDone", slot: "fetchContactsDone",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -551,7 +551,7 @@ QtObject:
return return
let arg = LookupContactTaskArg( let arg = LookupContactTaskArg(
tptr: lookupContactTask, tptr: lookupContactTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "ensResolved", slot: "ensResolved",
value: value, value: value,
chainId: self.networkService.getAppNetwork().chainId, chainId: self.networkService.getAppNetwork().chainId,
@ -639,7 +639,7 @@ QtObject:
try: try:
let arg = AsyncRequestContactInfoTaskArg( let arg = AsyncRequestContactInfoTaskArg(
tptr: asyncRequestContactInfoTask, tptr: asyncRequestContactInfoTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncContactInfoLoaded", slot: "asyncContactInfoLoaded",
pubkey: pubkey, pubkey: pubkey,
) )
@ -673,7 +673,7 @@ QtObject:
pubkey: contactId, pubkey: contactId,
validate: validate, validate: validate,
tptr: asyncGetProfileShowcaseForContactTask, tptr: asyncGetProfileShowcaseForContactTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncProfileShowcaseForContactLoaded", slot: "asyncProfileShowcaseForContactLoaded",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -700,7 +700,7 @@ QtObject:
let arg = FetchProfileShowcaseAccountsTaskArg( let arg = FetchProfileShowcaseAccountsTaskArg(
address: address, address: address,
tptr: fetchProfileShowcaseAccountsTask, tptr: fetchProfileShowcaseAccountsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onProfileShowcaseAccountsByAddressFetched", slot: "onProfileShowcaseAccountsByAddressFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)

View File

@ -97,7 +97,7 @@ QtObject:
proc fetchAllCurrencyFormats(self: Service) = proc fetchAllCurrencyFormats(self: Service) =
let arg = FetchAllCurrencyFormatsTaskArg( let arg = FetchAllCurrencyFormatsTaskArg(
tptr: fetchAllCurrencyFormatsTaskArg, tptr: fetchAllCurrencyFormatsTaskArg,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAllCurrencyFormatsFetched", slot: "onAllCurrencyFormatsFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)

View File

@ -115,7 +115,7 @@ QtObject:
proc asyncLoadDevices*(self: Service) = proc asyncLoadDevices*(self: Service) =
let arg = AsyncLoadDevicesTaskArg( let arg = AsyncLoadDevicesTaskArg(
tptr: asyncLoadDevicesTask, tptr: asyncLoadDevicesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncDevicesLoaded", slot: "asyncDevicesLoaded",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -244,7 +244,7 @@ QtObject:
let arg = AsyncInputConnectionStringArg( let arg = AsyncInputConnectionStringArg(
tptr: asyncInputConnectionStringTask, tptr: asyncInputConnectionStringTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "inputConnectionStringForBootstrappingFinished", slot: "inputConnectionStringForBootstrappingFinished",
connectionString: connectionString, connectionString: connectionString,
configJSON: $configJSON configJSON: $configJSON
@ -366,7 +366,7 @@ QtObject:
let arg = AsyncInputConnectionStringArg( let arg = AsyncInputConnectionStringArg(
tptr: asyncInputConnectionStringForImportingKeystoreTask, tptr: asyncInputConnectionStringForImportingKeystoreTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "inputConnectionStringForImportingKeystoreFinished", slot: "inputConnectionStringForImportingKeystoreFinished",
connectionString: connectionString, connectionString: connectionString,
configJSON: $configJSON configJSON: $configJSON

View File

@ -291,7 +291,7 @@ QtObject:
else: else:
let arg = CheckEnsAvailabilityTaskArg( let arg = CheckEnsAvailabilityTaskArg(
tptr: checkEnsAvailabilityTask, tptr: checkEnsAvailabilityTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onEnsUsernameAvailabilityChecked", slot: "onEnsUsernameAvailabilityChecked",
ensUsername: ensUsername, ensUsername: ensUsername,
chainId: self.getChainId(), chainId: self.getChainId(),
@ -332,7 +332,7 @@ QtObject:
let arg = EnsUsernamDetailsTaskArg( let arg = EnsUsernamDetailsTaskArg(
tptr: ensUsernameDetailsTask, tptr: ensUsernameDetailsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onEnsUsernameDetailsFetched", slot: "onEnsUsernameDetailsFetched",
ensUsername: username, ensUsername: username,
chainId: chainId, chainId: chainId,

View File

@ -69,7 +69,7 @@ QtObject:
proc runTimer(self: Service) = proc runTimer(self: Service) =
let arg = TimerTaskArg( let arg = TimerTaskArg(
tptr: timerTask, tptr: timerTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onTimeout", slot: "onTimeout",
timeoutInMilliseconds: TimerIntervalInMilliseconds timeoutInMilliseconds: TimerIntervalInMilliseconds
) )

View File

@ -69,7 +69,7 @@ QtObject:
try: try:
let arg = AsyncGetRecentGifsTaskArg( let arg = AsyncGetRecentGifsTaskArg(
tptr: asyncGetRecentGifsTask, tptr: asyncGetRecentGifsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetRecentGifsDone" slot: "onAsyncGetRecentGifsDone"
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -92,7 +92,7 @@ QtObject:
try: try:
let arg = AsyncGetFavoriteGifsTaskArg( let arg = AsyncGetFavoriteGifsTaskArg(
tptr: asyncGetFavoriteGifsTask, tptr: asyncGetFavoriteGifsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetFavoriteGifsDone" slot: "onAsyncGetFavoriteGifsDone"
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -118,7 +118,7 @@ QtObject:
self.events.emit(SIGNAL_SEARCH_GIFS_STARTED, Args()) self.events.emit(SIGNAL_SEARCH_GIFS_STARTED, Args())
let arg = AsyncTenorQueryArg( let arg = AsyncTenorQueryArg(
tptr: asyncTenorQuery, tptr: asyncTenorQuery,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncTenorQueryDone", slot: "onAsyncTenorQueryDone",
apiKeySet: self.apiKeySet, apiKeySet: self.apiKeySet,
apiKey: TENOR_API_KEY_RESOLVED, apiKey: TENOR_API_KEY_RESOLVED,
@ -138,7 +138,7 @@ QtObject:
self.events.emit(SIGNAL_LOAD_TRENDING_GIFS_STARTED, Args()) self.events.emit(SIGNAL_LOAD_TRENDING_GIFS_STARTED, Args())
let arg = AsyncTenorQueryArg( let arg = AsyncTenorQueryArg(
tptr: asyncTenorQuery, tptr: asyncTenorQuery,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncTenorQueryDone", slot: "onAsyncTenorQueryDone",
apiKeySet: self.apiKeySet, apiKeySet: self.apiKeySet,
apiKey: TENOR_API_KEY_RESOLVED, apiKey: TENOR_API_KEY_RESOLVED,

View File

@ -260,7 +260,7 @@ QtObject:
let arg = TimerTaskArg( let arg = TimerTaskArg(
tptr: timerTask, tptr: timerTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onTimeout", slot: "onTimeout",
timeoutInMilliseconds: timeoutInMilliseconds, timeoutInMilliseconds: timeoutInMilliseconds,
reason: reason reason: reason

View File

@ -50,7 +50,7 @@ QtObject:
proc setPin*(self: Service, pin: string) = proc setPin*(self: Service, pin: string) =
let arg = AsyncSetPinTaskArg( let arg = AsyncSetPinTaskArg(
tptr: asyncSetPinTask, tptr: asyncSetPinTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSetPinResponse", slot: "onAsyncSetPinResponse",
pin: pin, pin: pin,
) )

View File

@ -129,7 +129,7 @@ QtObject:
proc requestMoreMessages*(self: Service, chatId: string) = proc requestMoreMessages*(self: Service, chatId: string) =
let arg = RequestMoreMessagesTaskArg( let arg = RequestMoreMessagesTaskArg(
tptr: requestMoreMessagesTask, tptr: requestMoreMessagesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
chatId: chatId, chatId: chatId,
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -137,7 +137,7 @@ QtObject:
proc fillGaps*(self: Service, chatId: string, messageId: string) = proc fillGaps*(self: Service, chatId: string, messageId: string) =
let arg = FillGapsTaskArg( let arg = FillGapsTaskArg(
tptr: fillGapsTask, tptr: fillGapsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
chatId: chatId, chatId: chatId,
messageIds: @[messageId] messageIds: @[messageId]
) )
@ -237,7 +237,7 @@ QtObject:
#let mailserverWorker = self.marathon[MailserverWorker().name] #let mailserverWorker = self.marathon[MailserverWorker().name]
#let task = GetActiveMailserverTaskArg( #let task = GetActiveMailserverTaskArg(
# `proc`: "getActiveMailserver", # `proc`: "getActiveMailserver",
# vptr: cast[ByteAddress](self.vptr), # vptr: cast[uint](self.vptr),
# slot: "onActiveMailserverResult" # slot: "onActiveMailserverResult"
# ) # )
#mailserverWorker.start(task) #mailserverWorker.start(task)

View File

@ -236,7 +236,7 @@ QtObject:
let arg = AsyncFetchChatMessagesTaskArg( let arg = AsyncFetchChatMessagesTaskArg(
tptr: asyncFetchChatMessagesTask, tptr: asyncFetchChatMessagesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncLoadMoreMessagesForChat", slot: "onAsyncLoadMoreMessagesForChat",
chatId: chatId, chatId: chatId,
msgCursor: msgCursorValue, msgCursor: msgCursorValue,
@ -260,7 +260,7 @@ QtObject:
let arg = AsyncFetchChatMessagesTaskArg( let arg = AsyncFetchChatMessagesTaskArg(
tptr: asyncFetchPinnedChatMessagesTask, tptr: asyncFetchPinnedChatMessagesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncLoadPinnedMessagesForChat", slot: "onAsyncLoadPinnedMessagesForChat",
chatId: chatId, chatId: chatId,
msgCursor: pinnedMsgCursorValue, msgCursor: pinnedMsgCursorValue,
@ -285,7 +285,7 @@ QtObject:
communityId: communityId, communityId: communityId,
memberPubKey: memberPublicKey, memberPubKey: memberPublicKey,
tptr: asyncLoadCommunityMemberAllMessagesTask, tptr: asyncLoadCommunityMemberAllMessagesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncLoadCommunityMemberAllMessages" slot: "onAsyncLoadCommunityMemberAllMessages"
) )
@ -673,7 +673,7 @@ QtObject:
let arg = AsyncMarkMessageAsUnreadTaskArg( let arg = AsyncMarkMessageAsUnreadTaskArg(
tptr: asyncMarkMessageAsUnreadTask, tptr: asyncMarkMessageAsUnreadTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncMarkMessageAsUnread", slot: "onAsyncMarkMessageAsUnread",
messageId: messageId, messageId: messageId,
chatId: chatId chatId: chatId
@ -724,7 +724,7 @@ QtObject:
let requestId = genUUID() let requestId = genUUID()
let arg = AsyncGetMessageByMessageIdTaskArg( let arg = AsyncGetMessageByMessageIdTaskArg(
tptr: asyncGetMessageByMessageIdTask, tptr: asyncGetMessageByMessageIdTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetMessageById", slot: "onAsyncGetMessageById",
requestId: $requestId, requestId: $requestId,
messageId: messageId, messageId: messageId,
@ -776,7 +776,7 @@ QtObject:
let arg = AsyncSearchMessagesInChatTaskArg( let arg = AsyncSearchMessagesInChatTaskArg(
tptr: asyncSearchMessagesInChatTask, tptr: asyncSearchMessagesInChatTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSearchMessages", slot: "onAsyncSearchMessages",
chatId: chatId, chatId: chatId,
searchTerm: searchTerm, searchTerm: searchTerm,
@ -799,7 +799,7 @@ QtObject:
let arg = AsyncSearchMessagesInChatsAndCommunitiesTaskArg( let arg = AsyncSearchMessagesInChatsAndCommunitiesTaskArg(
tptr: asyncSearchMessagesInChatsAndCommunitiesTask, tptr: asyncSearchMessagesInChatsAndCommunitiesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSearchMessages", slot: "onAsyncSearchMessages",
communityIds: communityIds, communityIds: communityIds,
chatIds: chatIds, chatIds: chatIds,
@ -835,7 +835,7 @@ QtObject:
let arg = AsyncMarkAllMessagesReadTaskArg( let arg = AsyncMarkAllMessagesReadTaskArg(
tptr: asyncMarkAllMessagesReadTask, tptr: asyncMarkAllMessagesReadTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onMarkAllMessagesRead", slot: "onMarkAllMessagesRead",
chatId: chatId chatId: chatId
) )
@ -920,7 +920,7 @@ QtObject:
let arg = AsyncMarkCertainMessagesReadTaskArg( let arg = AsyncMarkCertainMessagesReadTaskArg(
tptr: asyncMarkCertainMessagesReadTask, tptr: asyncMarkCertainMessagesReadTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onMarkCertainMessagesRead", slot: "onMarkCertainMessagesRead",
chatId: chatId, chatId: chatId,
messagesIds: messagesIds messagesIds: messagesIds
@ -931,7 +931,7 @@ QtObject:
proc getAsyncFirstUnseenMessageId*(self: Service, chatId: string) = proc getAsyncFirstUnseenMessageId*(self: Service, chatId: string) =
let arg = AsyncGetFirstUnseenMessageIdForTaskArg( let arg = AsyncGetFirstUnseenMessageIdForTaskArg(
tptr: asyncGetFirstUnseenMessageIdForTaskArg, tptr: asyncGetFirstUnseenMessageIdForTaskArg,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onGetFirstUnseenMessageIdFor", slot: "onGetFirstUnseenMessageIdFor",
chatId: chatId, chatId: chatId,
) )
@ -994,7 +994,7 @@ QtObject:
let uuid = $genUUID() let uuid = $genUUID()
let arg = AsyncGetTextURLsToUnfurlTaskArg( let arg = AsyncGetTextURLsToUnfurlTaskArg(
tptr: asyncGetTextURLsToUnfurlTask, tptr: asyncGetTextURLsToUnfurlTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetTextURLsToUnfurl", slot: "onAsyncGetTextURLsToUnfurl",
text: text, text: text,
requestUuid: uuid, requestUuid: uuid,
@ -1050,7 +1050,7 @@ QtObject:
let uuid = $genUUID() let uuid = $genUUID()
let arg = AsyncUnfurlUrlsTaskArg( let arg = AsyncUnfurlUrlsTaskArg(
tptr: asyncUnfurlUrlsTask, tptr: asyncUnfurlUrlsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncUnfurlUrlsFinished", slot: "onAsyncUnfurlUrlsFinished",
urls: urls, urls: urls,
requestUuid: uuid, requestUuid: uuid,

View File

@ -45,7 +45,7 @@ QtObject:
proc addCentralizedMetricIfEnabled*(self: MetricsService, eventName: string, eventValueJson: string) {.slot.} = proc addCentralizedMetricIfEnabled*(self: MetricsService, eventName: string, eventValueJson: string) {.slot.} =
let arg = AsyncAddCentralizedMetricIfEnabledTaskArg( let arg = AsyncAddCentralizedMetricIfEnabledTaskArg(
tptr: asyncAddCentralizedMetricIfEnabledTask, tptr: asyncAddCentralizedMetricIfEnabledTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onCentralizedMetricAddedIdEnabled", slot: "onCentralizedMetricAddedIdEnabled",
eventName: eventName, eventName: eventName,
eventValueJson: eventValueJson, eventValueJson: eventValueJson,

View File

@ -112,7 +112,7 @@ QtObject:
let loggedInAccount = self.accountsService.getLoggedInAccount() let loggedInAccount = self.accountsService.getLoggedInAccount()
let arg = ChangeDatabasePasswordTaskArg( let arg = ChangeDatabasePasswordTaskArg(
tptr: changeDatabasePasswordTask, tptr: changeDatabasePasswordTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onChangeDatabasePasswordResponse", slot: "onChangeDatabasePasswordResponse",
accountId: loggedInAccount.keyUid, accountId: loggedInAccount.keyUid,
currentPassword: common_utils.hashPassword(password), currentPassword: common_utils.hashPassword(password),

View File

@ -116,7 +116,7 @@ QtObject:
proc requestProfileShowcasePreferences*(self: Service) = proc requestProfileShowcasePreferences*(self: Service) =
let arg = QObjectTaskArg( let arg = QObjectTaskArg(
tptr: asyncGetProfileShowcasePreferencesTask, tptr: asyncGetProfileShowcasePreferencesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncProfileShowcasePreferencesLoaded", slot: "asyncProfileShowcasePreferencesLoaded",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -139,7 +139,7 @@ QtObject:
let arg = SaveProfileShowcasePreferencesTaskArg( let arg = SaveProfileShowcasePreferencesTaskArg(
preferences: preferences, preferences: preferences,
tptr: saveProfileShowcasePreferencesTask, tptr: saveProfileShowcasePreferencesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "asyncProfileShowcasePreferencesSaved", slot: "asyncProfileShowcasePreferencesSaved",
) )
self.threadpool.start(arg) self.threadpool.start(arg)

View File

@ -68,7 +68,7 @@ QtObject:
proc postMessage*(self: Service, payloadMethod: string, requestType: string, message: string) = proc postMessage*(self: Service, payloadMethod: string, requestType: string, message: string) =
let arg = PostMessageTaskArg( let arg = PostMessageTaskArg(
tptr: postMessageTask, tptr: postMessageTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "postMessageResolved", slot: "postMessageResolved",
payloadMethod: payloadMethod, payloadMethod: payloadMethod,
requestType: requestType, requestType: requestType,

View File

@ -52,7 +52,7 @@ QtObject:
proc fetchCryptoRampProviders*(self: Service) = proc fetchCryptoRampProviders*(self: Service) =
let arg = QObjectTaskArg( let arg = QObjectTaskArg(
tptr: getCryptoServicesTask, tptr: getCryptoServicesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onFetchCryptoRampProviders", slot: "onFetchCryptoRampProviders",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -69,7 +69,7 @@ QtObject:
proc fetchCryptoRampUrl*(self: Service, uuid: string, providerID: string, parameters: CryptoRampParametersDto) = proc fetchCryptoRampUrl*(self: Service, uuid: string, providerID: string, parameters: CryptoRampParametersDto) =
let arg = GetCryptoRampUrlTaskArg( let arg = GetCryptoRampUrlTaskArg(
tptr: getCryptoRampURLTask, tptr: getCryptoRampURLTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onFetchCryptoRampURL", slot: "onFetchCryptoRampURL",
uuid: uuid, uuid: uuid,
providerID: providerID, providerID: providerID,

View File

@ -96,7 +96,7 @@ QtObject:
let arg = SavedAddressTaskArg( let arg = SavedAddressTaskArg(
chainId: self.networkService.getAppNetwork().chainId, chainId: self.networkService.getAppNetwork().chainId,
tptr: fetchSavedAddressesAndResolveEnsNamesTask, tptr: fetchSavedAddressesAndResolveEnsNamesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onSavedAddressesFetched", slot: "onSavedAddressesFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -123,7 +123,7 @@ QtObject:
colorId: colorId, colorId: colorId,
isTestAddress: self.areTestNetworksEnabled(), isTestAddress: self.areTestNetworksEnabled(),
tptr: upsertSavedAddressTask, tptr: upsertSavedAddressTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onSavedAddressCreatedOrUpdated", slot: "onSavedAddressCreatedOrUpdated",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -150,7 +150,7 @@ QtObject:
address: address, address: address,
isTestAddress: self.areTestNetworksEnabled(), isTestAddress: self.areTestNetworksEnabled(),
tptr: deleteSavedAddressTask, tptr: deleteSavedAddressTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onDeleteSavedAddress", slot: "onDeleteSavedAddress",
) )
self.threadpool.start(arg) self.threadpool.start(arg)

View File

@ -210,7 +210,7 @@ QtObject:
let arg = ObtainMarketStickerPacksTaskArg( let arg = ObtainMarketStickerPacksTaskArg(
tptr: obtainMarketStickerPacksTask, tptr: obtainMarketStickerPacksTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "setMarketStickerPacks", slot: "setMarketStickerPacks",
chainId: chainId, chainId: chainId,
) )
@ -245,7 +245,7 @@ QtObject:
try: try:
let arg = AsyncGetRecentStickersTaskArg( let arg = AsyncGetRecentStickersTaskArg(
tptr: asyncGetRecentStickersTask, tptr: asyncGetRecentStickersTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetRecentStickersDone" slot: "onAsyncGetRecentStickersDone"
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -269,7 +269,7 @@ QtObject:
try: try:
let arg = AsyncGetInstalledStickerPacksTaskArg( let arg = AsyncGetInstalledStickerPacksTaskArg(
tptr: asyncGetInstalledStickerPacksTask, tptr: asyncGetInstalledStickerPacksTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncGetInstalledStickerPacksDone" slot: "onAsyncGetInstalledStickerPacksDone"
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -300,7 +300,7 @@ QtObject:
proc installStickerPack*(self: Service, packId: string) = proc installStickerPack*(self: Service, packId: string) =
let arg = InstallStickerPackTaskArg( let arg = InstallStickerPackTaskArg(
tptr: installStickerPackTask, tptr: installStickerPackTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onStickerPackInstalled", slot: "onStickerPackInstalled",
chainId: self.networkService.getAppNetwork().chainId, chainId: self.networkService.getAppNetwork().chainId,
packId: packId, packId: packId,
@ -332,7 +332,7 @@ QtObject:
preferredUsername: string) = preferredUsername: string) =
let arg = AsyncSendStickerTaskArg( let arg = AsyncSendStickerTaskArg(
tptr: asyncSendStickerTask, tptr: asyncSendStickerTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAsyncSendStickerDone", slot: "onAsyncSendStickerDone",
chatId: chatId, chatId: chatId,
replyTo: replyTo, replyTo: replyTo,

View File

@ -107,7 +107,7 @@ QtObject:
defer: self.events.emit(SIGNAL_TOKENS_MARKET_VALUES_ABOUT_TO_BE_UPDATED, Args()) defer: self.events.emit(SIGNAL_TOKENS_MARKET_VALUES_ABOUT_TO_BE_UPDATED, Args())
let arg = FetchTokensMarketValuesTaskArg( let arg = FetchTokensMarketValuesTaskArg(
tptr: fetchTokensMarketValuesTask, tptr: fetchTokensMarketValuesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "tokensMarketValuesRetrieved", slot: "tokensMarketValuesRetrieved",
symbols: symbols, symbols: symbols,
currency: self.getCurrency() currency: self.getCurrency()
@ -150,7 +150,7 @@ QtObject:
self.tokensDetailsLoading = true self.tokensDetailsLoading = true
let arg = FetchTokensDetailsTaskArg( let arg = FetchTokensDetailsTaskArg(
tptr: fetchTokensDetailsTask, tptr: fetchTokensDetailsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "tokensDetailsRetrieved", slot: "tokensDetailsRetrieved",
symbols: symbols symbols: symbols
) )
@ -190,7 +190,7 @@ QtObject:
defer: self.events.emit(SIGNAL_TOKENS_PRICES_ABOUT_TO_BE_UPDATED, Args()) defer: self.events.emit(SIGNAL_TOKENS_PRICES_ABOUT_TO_BE_UPDATED, Args())
let arg = FetchTokensPricesTaskArg( let arg = FetchTokensPricesTaskArg(
tptr: fetchTokensPricesTask, tptr: fetchTokensPricesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "tokensPricesRetrieved", slot: "tokensPricesRetrieved",
symbols: symbols, symbols: symbols,
currencies: @[self.getCurrency()] currencies: @[self.getCurrency()]
@ -362,7 +362,7 @@ QtObject:
proc getSupportedTokensList*(self: Service) = proc getSupportedTokensList*(self: Service) =
let arg = QObjectTaskArg( let arg = QObjectTaskArg(
tptr: getSupportedTokenList, tptr: getSupportedTokenList,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "supportedTokensListRetrieved", slot: "supportedTokensListRetrieved",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -499,7 +499,7 @@ QtObject:
proc getHistoricalDataForToken*(self: Service, symbol: string, currency: string, range: int) = proc getHistoricalDataForToken*(self: Service, symbol: string, currency: string, range: int) =
let arg = GetTokenHistoricalDataTaskArg( let arg = GetTokenHistoricalDataTaskArg(
tptr: getTokenHistoricalDataTask, tptr: getTokenHistoricalDataTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "tokenHistoricalDataResolved", slot: "tokenHistoricalDataResolved",
symbol: symbol, symbol: symbol,
currency: currency, currency: currency,

View File

@ -8,7 +8,7 @@ include ../../common/json_utils
import ../network/dto, ../token/dto import ../network/dto, ../token/dto
import ../../common/conversion as service_conversion import ../../common/conversion as service_conversion
import ./backend/transactions import ../../../backend/transactions
type type
SendType* {.pure.} = enum SendType* {.pure.} = enum

View File

@ -287,7 +287,7 @@ QtObject:
toAmount: toAmount, toAmount: toAmount,
data: data, data: data,
tptr: watchTransactionTask, tptr: watchTransactionTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "watchTransactionResult", slot: "watchTransactionResult",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -307,7 +307,7 @@ QtObject:
proc fetchDecodedTxData*(self: Service, txHash: string, data: string) = proc fetchDecodedTxData*(self: Service, txHash: string, data: string) =
let arg = FetchDecodedTxDataTaskArg( let arg = FetchDecodedTxDataTaskArg(
tptr: fetchDecodedTxDataTask, tptr: fetchDecodedTxDataTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
data: data, data: data,
txHash: txHash, txHash: txHash,
slot: "onFetchDecodedTxData", slot: "onFetchDecodedTxData",

View File

@ -12,7 +12,7 @@ proc fetchHistoricalBalanceForTokenAsJson*(self: Service, addresses: seq[string]
var chainIds: seq[int] = self.networkService.getEnabledChainIds() var chainIds: seq[int] = self.networkService.getEnabledChainIds()
let arg = GetTokenBalanceHistoryDataTaskArg( let arg = GetTokenBalanceHistoryDataTaskArg(
tptr: getTokenBalanceHistoryDataTask, tptr: getTokenBalanceHistoryDataTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "tokenBalanceHistoryDataResolved", slot: "tokenBalanceHistoryDataResolved",
chainIds: chainIds, chainIds: chainIds,
addresses: addresses, addresses: addresses,

View File

@ -460,7 +460,7 @@ proc migrateNonProfileKeycardKeypairToAppAsync*(self: Service, keyUid, seedPhras
finalPassword = utils.hashPassword(password) finalPassword = utils.hashPassword(password)
let arg = MigrateNonProfileKeycardKeypairToAppTaskArg( let arg = MigrateNonProfileKeycardKeypairToAppTaskArg(
tptr: migrateNonProfileKeycardKeypairToAppTask, tptr: migrateNonProfileKeycardKeypairToAppTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onNonProfileKeycardKeypairMigratedToApp", slot: "onNonProfileKeycardKeypairMigratedToApp",
keyUid: keyUid, keyUid: keyUid,
seedPhrase: seedPhrase, seedPhrase: seedPhrase,
@ -484,7 +484,7 @@ proc onENSNamesFetched*(self: Service, response: string) {.slot.} =
proc fetchENSNamesForAddressesAsync(self: Service, addresses: seq[string], chainId: int) = proc fetchENSNamesForAddressesAsync(self: Service, addresses: seq[string], chainId: int) =
let arg = FetchENSNamesForAddressesTaskArg( let arg = FetchENSNamesForAddressesTaskArg(
tptr: fetchENSNamesForAddressesTask, tptr: fetchENSNamesForAddressesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onENSNamesFetched", slot: "onENSNamesFetched",
addresses: addresses, addresses: addresses,
chainId: chainId chainId: chainId
@ -619,7 +619,7 @@ proc fetchDerivedAddresses*(self: Service, password: string, derivedFrom: string
derivedFrom: derivedFrom, derivedFrom: derivedFrom,
paths: paths, paths: paths,
tptr: fetchDerivedAddressesTask, tptr: fetchDerivedAddressesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onDerivedAddressesFetched", slot: "onDerivedAddressesFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -639,7 +639,7 @@ proc fetchDerivedAddressesForMnemonic*(self: Service, mnemonic: string, paths: s
mnemonic: mnemonic, mnemonic: mnemonic,
paths: paths, paths: paths,
tptr: fetchDerivedAddressesForMnemonicTask, tptr: fetchDerivedAddressesForMnemonicTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onDerivedAddressesForMnemonicFetched", slot: "onDerivedAddressesForMnemonicFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -660,7 +660,7 @@ proc fetchDetailsForAddresses*(self: Service, uniqueId: string, addresses: seq[s
uniqueId: uniqueId, uniqueId: uniqueId,
addresses: addresses, addresses: addresses,
tptr: fetchDetailsForAddressesTask, tptr: fetchDetailsForAddressesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAddressDetailsFetched", slot: "onAddressDetailsFetched",
) )
self.threadpool.start(arg) self.threadpool.start(arg)
@ -725,7 +725,7 @@ proc onFetchChainIdForUrl*(self: Service, jsonString: string) {.slot.} =
proc fetchChainIdForUrl*(self: Service, url: string, isMainUrl: bool) = proc fetchChainIdForUrl*(self: Service, url: string, isMainUrl: bool) =
let arg = FetchChainIdForUrlTaskArg( let arg = FetchChainIdForUrlTaskArg(
tptr: fetchChainIdForUrlTask, tptr: fetchChainIdForUrlTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onFetchChainIdForUrl", slot: "onFetchChainIdForUrl",
url: url, url: url,
isMainUrl: isMainUrl isMainUrl: isMainUrl

View File

@ -1,7 +1,7 @@
proc addKeycardOrAccountsAsync*(self: Service, keycard: KeycardDto, accountsComingFromKeycard: bool = false) = proc addKeycardOrAccountsAsync*(self: Service, keycard: KeycardDto, accountsComingFromKeycard: bool = false) =
let arg = SaveOrUpdateKeycardTaskArg( let arg = SaveOrUpdateKeycardTaskArg(
tptr: saveOrUpdateKeycardTask, tptr: saveOrUpdateKeycardTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onKeycardAdded", slot: "onKeycardAdded",
keycard: keycard, keycard: keycard,
accountsComingFromKeycard: accountsComingFromKeycard accountsComingFromKeycard: accountsComingFromKeycard
@ -60,7 +60,7 @@ proc addKeycardOrAccounts*(self: Service, keycard: KeycardDto, accountsComingFro
proc removeMigratedAccountsForKeycard*(self: Service, keyUid: string, keycardUid: string, accountsToRemove: seq[string]) = proc removeMigratedAccountsForKeycard*(self: Service, keyUid: string, keycardUid: string, accountsToRemove: seq[string]) =
let arg = DeleteKeycardAccountsTaskArg( let arg = DeleteKeycardAccountsTaskArg(
tptr: deleteKeycardAccountsTask, tptr: deleteKeycardAccountsTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onMigratedAccountsForKeycardRemoved", slot: "onMigratedAccountsForKeycardRemoved",
keycard: KeycardDto(keyUid: keyUid, keycardUid: keycardUid, accountsAddresses: accountsToRemove) keycard: KeycardDto(keyUid: keyUid, keycardUid: keycardUid, accountsAddresses: accountsToRemove)
) )

View File

@ -92,7 +92,7 @@ proc buildAllTokens*(self: Service, accounts: seq[string], store: bool) =
let arg = BuildTokensTaskArg( let arg = BuildTokensTaskArg(
tptr: prepareTokensTask, tptr: prepareTokensTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "onAllTokensBuilt", slot: "onAllTokensBuilt",
accounts: accounts, accounts: accounts,
storeResult: store storeResult: store

View File

@ -233,7 +233,7 @@ QtObject:
proc getEstimatedTime*(self: Service, topic: string, chainId: int, maxFeePerGasHex: string) = proc getEstimatedTime*(self: Service, topic: string, chainId: int, maxFeePerGasHex: string) =
let request = AsyncGetEstimatedTimeArgs( let request = AsyncGetEstimatedTimeArgs(
tptr: asyncGetEstimatedTimeTask, tptr: asyncGetEstimatedTimeTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "estimatedTimeResponse", slot: "estimatedTimeResponse",
topic: topic, topic: topic,
chainId: chainId, chainId: chainId,
@ -256,7 +256,7 @@ QtObject:
proc requestSuggestedFees*(self: Service, topic: string, chainId: int) = proc requestSuggestedFees*(self: Service, topic: string, chainId: int) =
let request = AsyncSuggestedFeesArgs( let request = AsyncSuggestedFeesArgs(
tptr: asyncSuggestedFeesTask, tptr: asyncSuggestedFeesTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "suggestedFeesResponse", slot: "suggestedFeesResponse",
topic: topic, topic: topic,
chainId: chainId chainId: chainId
@ -315,7 +315,7 @@ QtObject:
proc requestGasEstimate*(self: Service, topic: string, tx: JsonNode, chainId: int) = proc requestGasEstimate*(self: Service, topic: string, tx: JsonNode, chainId: int) =
let request = AsyncEstimateGasArgs( let request = AsyncEstimateGasArgs(
tptr: asyncEstimateGasTask, tptr: asyncEstimateGasTask,
vptr: cast[ByteAddress](self.vptr), vptr: cast[uint](self.vptr),
slot: "estimatedGasResponse", slot: "estimatedGasResponse",
topic: topic, topic: topic,
chainId: chainId, chainId: chainId,

View File

@ -22,7 +22,7 @@ proc isSuccessResponse(rpcResponse: RpcResponse[JsonNode]): bool =
proc addSession*(sessionJson: string): bool = proc addSession*(sessionJson: string): bool =
try: try:
let rpcRes = addWalletConnectSession(sessionJson) let rpcRes = addWalletConnectSession(sessionJson)
return isSuccessResponse(rpcRes): return isSuccessResponse(rpcRes)
except Exception as e: except Exception as e:
error "AddWalletConnectSession failed: ", "msg", e.msg error "AddWalletConnectSession failed: ", "msg", e.msg
return false return false
@ -30,7 +30,7 @@ proc addSession*(sessionJson: string): bool =
proc disconnectSession*(topic: string): bool = proc disconnectSession*(topic: string): bool =
try: try:
let rpcRes = disconnectWalletConnectSession(topic) let rpcRes = disconnectWalletConnectSession(topic)
return isSuccessResponse(rpcRes): return isSuccessResponse(rpcRes)
except Exception as e: except Exception as e:
error "wallet_disconnectWalletConnectSession failed: ", "msg", e.msg error "wallet_disconnectWalletConnectSession failed: ", "msg", e.msg
return false return false

View File

@ -1,4 +1,4 @@
import NimQml, chronicles, os, stew/shims/strformat, strutils, times, md5, json, re import NimQml, chronicles, os, stew/shims/strformat, strutils, times, checksums/md5, json, re
import status_go import status_go
import keycard_go import keycard_go

1
vendor/checksums vendored Submodule

@ -0,0 +1 @@
Subproject commit f8f6bd34bfa3fe12c64b919059ad856a96efcba0

2
vendor/nim-bearssl vendored

@ -1 +1 @@
Subproject commit a806cbfab5fe8de49c76139f8705fff79daf99ee Subproject commit 667b40440a53a58e9f922e29e20818720c62d9ac

@ -1 +1 @@
Subproject commit 1ac2715bbbb1f2931ce2d32fe05b70f8d47fe413 Subproject commit 4524912fcacfd3965e32a9fe23c9bb12d48177ff

2
vendor/nim-chronos vendored

@ -1 +1 @@
Subproject commit f7835a192b45c37e97614d865141f21eea8c156e Subproject commit c04576d829b8a0a1b12baaa8bc92037501b3a4a0

@ -1 +1 @@
Subproject commit 0adf3b7db70736061bf12fa23c2fc51f395b289e Subproject commit cb640db2cd66d7f4a1810a7df51b55f6f59cf3c5

2
vendor/nim-eth vendored

@ -1 +1 @@
Subproject commit 5aaeb67ebedbefaae2f719f245a96c1a80c42f81 Subproject commit bb5cb6a4d0dbb592b395ab41cda3fd3f1fdc443e

@ -1 +1 @@
Subproject commit 11b9d952a80ec87e2443405a6a5382f9daac51f8 Subproject commit dbc4a95df60238157dcf286f6125188cb72f37c1

@ -1 +1 @@
Subproject commit be57dbc902d36f37540897e98c69aa80f868cb45 Subproject commit 8b88ad6dd9a6326c29f82067800c483d9410d873

@ -1 +1 @@
Subproject commit a7d815ed92f200f490c95d3cfd722089cc923ce6 Subproject commit 8a4ed98bbd0a9479df15af2fa31da38a586ea6d5

2
vendor/nim-libp2p vendored

@ -1 +1 @@
Subproject commit e3c967ad1939fb33b8e13759037d193734acd202 Subproject commit 8855bce0854ecf4adad7a0556bb2b2d2f98e0e20

2
vendor/nim-metrics vendored

@ -1 +1 @@
Subproject commit 51f1227d0fd04ce84b1ef784b11280cb7875348c Subproject commit 29bb7ba63cd884770169891687595348a70cf166

2
vendor/nim-result vendored

@ -1 +1 @@
Subproject commit e2adf66b8bc2f41606e8469a5f0a850d1e545b55 Subproject commit 71d404b314479a6205bfd050f4fe5fe49cdafc69

@ -1 +1 @@
Subproject commit 194b715b16766e383b5aef92dd779fb182faf45d Subproject commit 4470f49bcd6bcbfb59f0eeb67315ca9ddac0bdc0

@ -1 +1 @@
Subproject commit 4d541ec43454809904fc4c3c0a7436410ad597d2 Subproject commit 298a9554a885b2df59737bb3461aac8d0d339724

2
vendor/nim-stew vendored

@ -1 +1 @@
Subproject commit bb086e69da967ad235ed6c31247769e75b318e61 Subproject commit d4634c5405ac188e7050d348332edb6c3b09a527

2
vendor/nim-stint vendored

@ -1 +1 @@
Subproject commit 9a3348bd4499045fb211afeeaf2a54730060c081 Subproject commit 7c81df9adc80088f46a4c2b8bf2a46c26fab057c

2
vendor/nim-web3 vendored

@ -1 +1 @@
Subproject commit 6a854220ea23ae0a7f284aaf490c81dcc1b42ead Subproject commit 428b931e7c4f1284b4272bc2c11fca2bd70991cd

2
vendor/nim-websock vendored

@ -1 +1 @@
Subproject commit f8ed9b40a5ff27ad02a3c237c4905b0924e3f982 Subproject commit 63bcc2902d884c63101e144555ad99421734a70a

@ -1 +1 @@
Subproject commit cf0c9cfa408189c6d428799bf2e9da8d0c0f7f08 Subproject commit 8fafcd0bac9f409091b7bcaee62ab6330f57441e

2
vendor/uuids vendored

@ -1 +1 @@
Subproject commit c5039c1cc6a8a93fc2f3c03a206372eb4412e63b Subproject commit 42052ba362a9cd4685463edb3781beeb9b8e547e