mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-19 20:48:09 +00:00
fix(ui/views/App/Main/MainWindow): handle closing correctly on mac os
This commit is contained in:
parent
4dcb43092b
commit
e482fb9e1c
3 changed files with 13 additions and 4 deletions
|
|
@ -10,9 +10,14 @@ Flickable {
|
|||
property alias text: textArea.text
|
||||
readonly property alias length: textArea.length
|
||||
|
||||
boundsBehavior: Flickable.StopAtBounds
|
||||
height: TextAreaFieldStyle.background.height
|
||||
width: TextAreaFieldStyle.background.width
|
||||
|
||||
ScrollBar.vertical: ForceScrollBar {
|
||||
id: scrollBar
|
||||
}
|
||||
|
||||
TextArea.flickable: TextArea {
|
||||
id: textArea
|
||||
|
||||
|
|
@ -39,8 +44,4 @@ Flickable {
|
|||
rightPadding: TextAreaFieldStyle.text.padding + Number(scrollBar.visible) * scrollBar.width
|
||||
topPadding: TextAreaFieldStyle.text.padding
|
||||
}
|
||||
|
||||
ScrollBar.vertical: ForceScrollBar {
|
||||
id: scrollBar
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,13 @@ function handleActiveFocusItemChanged (activeFocusItem) {
|
|||
}
|
||||
}
|
||||
|
||||
function handleClosing (close) {
|
||||
if (Qt.platform.os === 'osx') {
|
||||
close.accepted = false
|
||||
window.showMinimized()
|
||||
}
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
function lockView (info) {
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ ApplicationWindow {
|
|||
// ---------------------------------------------------------------------------
|
||||
|
||||
onActiveFocusItemChanged: Logic.handleActiveFocusItemChanged(activeFocusItem)
|
||||
onClosing: Logic.handleClosing(close)
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue