mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-24 21:42:51 -05:00
notepad: fix unsave changed dialog height
This commit is contained in:
@@ -692,6 +692,7 @@ Item {
|
|||||||
data: item,
|
data: item,
|
||||||
pluginId: pluginId,
|
pluginId: pluginId,
|
||||||
isBuiltInLauncher: true,
|
isBuiltInLauncher: true,
|
||||||
|
keywords: item.keywords || [],
|
||||||
actions: [],
|
actions: [],
|
||||||
primaryAction: {
|
primaryAction: {
|
||||||
name: I18n.tr("Open"),
|
name: I18n.tr("Open"),
|
||||||
@@ -1198,6 +1199,7 @@ Item {
|
|||||||
section: "plugin_" + pluginId,
|
section: "plugin_" + pluginId,
|
||||||
data: item,
|
data: item,
|
||||||
pluginId: pluginId,
|
pluginId: pluginId,
|
||||||
|
keywords: item.keywords || [],
|
||||||
actions: item.actions || [],
|
actions: item.actions || [],
|
||||||
primaryAction: item.primaryAction || {
|
primaryAction: item.primaryAction || {
|
||||||
name: I18n.tr("Select"),
|
name: I18n.tr("Select"),
|
||||||
|
|||||||
@@ -200,7 +200,7 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
onPreviewRequested: {
|
onPreviewRequested: {
|
||||||
textEditor.togglePreview()
|
textEditor.togglePreview();
|
||||||
}
|
}
|
||||||
|
|
||||||
onEscapePressed: {
|
onEscapePressed: {
|
||||||
@@ -362,8 +362,8 @@ Item {
|
|||||||
DankModal {
|
DankModal {
|
||||||
id: confirmationDialog
|
id: confirmationDialog
|
||||||
|
|
||||||
width: 400
|
modalWidth: 400
|
||||||
height: 180
|
modalHeight: contentLoader.item ? contentLoader.item.implicitHeight + Theme.spacingM * 2 : 180
|
||||||
shouldBeVisible: false
|
shouldBeVisible: false
|
||||||
allowStacking: true
|
allowStacking: true
|
||||||
|
|
||||||
@@ -376,6 +376,7 @@ Item {
|
|||||||
FocusScope {
|
FocusScope {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
focus: true
|
focus: true
|
||||||
|
implicitHeight: contentColumn.implicitHeight
|
||||||
|
|
||||||
Keys.onEscapePressed: event => {
|
Keys.onEscapePressed: event => {
|
||||||
confirmationDialog.close();
|
confirmationDialog.close();
|
||||||
@@ -384,17 +385,13 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
anchors.centerIn: parent
|
id: contentColumn
|
||||||
width: parent.width - Theme.spacingM * 2
|
anchors.left: parent.left
|
||||||
|
anchors.right: parent.right
|
||||||
|
anchors.top: parent.top
|
||||||
|
anchors.margins: Theme.spacingM
|
||||||
spacing: Theme.spacingM
|
spacing: Theme.spacingM
|
||||||
|
|
||||||
Row {
|
|
||||||
width: parent.width
|
|
||||||
|
|
||||||
Column {
|
|
||||||
width: parent.width - 40
|
|
||||||
spacing: Theme.spacingXS
|
|
||||||
|
|
||||||
StyledText {
|
StyledText {
|
||||||
text: I18n.tr("Unsaved Changes")
|
text: I18n.tr("Unsaved Changes")
|
||||||
font.pixelSize: Theme.fontSizeLarge
|
font.pixelSize: Theme.fontSizeLarge
|
||||||
@@ -409,22 +406,10 @@ Item {
|
|||||||
width: parent.width
|
width: parent.width
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
DankActionButton {
|
|
||||||
iconName: "close"
|
|
||||||
iconSize: Theme.iconSize - 4
|
|
||||||
iconColor: Theme.surfaceText
|
|
||||||
onClicked: {
|
|
||||||
confirmationDialog.close();
|
|
||||||
root.confirmationDialogOpen = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: 40
|
height: 36
|
||||||
|
|
||||||
Row {
|
Row {
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
@@ -515,6 +500,20 @@ Item {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DankActionButton {
|
||||||
|
anchors.top: parent.top
|
||||||
|
anchors.right: parent.right
|
||||||
|
anchors.topMargin: Theme.spacingM
|
||||||
|
anchors.rightMargin: Theme.spacingM
|
||||||
|
iconName: "close"
|
||||||
|
iconSize: Theme.iconSize - 4
|
||||||
|
iconColor: Theme.surfaceText
|
||||||
|
onClicked: {
|
||||||
|
confirmationDialog.close();
|
||||||
|
root.confirmationDialogOpen = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user