mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-22 04:21:44 +00:00
fix: fix top bar menu position
This commit is contained in:
parent
6c272dddf6
commit
90e9e2d192
@ -109,7 +109,9 @@ Rectangle {
|
||||
if (isPrivateGroupChat) {
|
||||
menu.popup(moreActionsBtn.x, moreActionsBtn.height)
|
||||
} else {
|
||||
menu.openMenu(chatsModel.activeChannel, chatsModel.getActiveChannelIdx())
|
||||
menu.openMenu(chatsModel.activeChannel, chatsModel.getActiveChannelIdx(),
|
||||
moreActionsBtn.x - chatContextMenu.width + moreActionsBtn.width + 4,
|
||||
moreActionsBtn.height - 4)
|
||||
}
|
||||
}
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
|
@ -25,15 +25,16 @@ PopupMenu {
|
||||
}
|
||||
]
|
||||
|
||||
function openMenu(channel, index) {
|
||||
function openMenu(channel, index, x, y) {
|
||||
channelContextMenu.contextChannel = channel
|
||||
if (index !== undefined) {
|
||||
channelContextMenu.channelIndex = index
|
||||
}
|
||||
channelContextMenu.popup()
|
||||
channelContextMenu.popup(x, y)
|
||||
}
|
||||
|
||||
Action {
|
||||
id: viewProfileButton
|
||||
enabled: channelContextMenu.contextChannel.chatType !== Constants.chatTypePublic
|
||||
text: {
|
||||
if (channelContextMenu.contextChannel.chatType === Constants.chatTypeOneToOne) {
|
||||
@ -65,7 +66,9 @@ PopupMenu {
|
||||
}
|
||||
}
|
||||
|
||||
Separator {}
|
||||
Separator {
|
||||
visible: viewProfileButton.enabled
|
||||
}
|
||||
|
||||
Action {
|
||||
text: channelContextMenu.contextChannel.muted ?
|
||||
|
Loading…
x
Reference in New Issue
Block a user