Commit 872b07e2 authored by Camilo Higuita's avatar Camilo Higuita

new dialog now on mauikit and use it

parent 36e459f2
......@@ -140,12 +140,15 @@ Maui.ApplicationWindow
onSaveToClicked:
{
console.log(path)
fmDialog.saveDialog = false
fmDialog.multipleSelection = true
fmDialog.onlyDirs= true
var myPath = path
fmDialog.show(function(selectedPaths)
{
console.log("EMITIDOooooooo", myPath, selectedPaths.length)
// inx.copy()
Maui.FM.copy(selectedPaths, myPath)
})
}
......@@ -162,19 +165,19 @@ Maui.ApplicationWindow
onShareClicked: shareDialog.show(path)
}
NewDialog
Maui.NewDialog
{
id: newFolderDialog
title: "New folder..."
onFinished: inx.createDir(browser.currentPath, text)
onFinished: Maui.FM.createDir(browser.currentPath, text)
}
NewDialog
Maui.NewDialog
{
id: newFileDialog
title: "New file..."
onFinished: inx.createFile(browser.currentPath, text)
onFinished: Maui.FM.createFile(browser.currentPath, text)
}
Maui.ShareDialog
......@@ -187,7 +190,5 @@ Maui.ApplicationWindow
Maui.FileDialog
{
id:fmDialog
onlyDirs: true
onSelectionReady: console.log(paths.length)
}
}
......@@ -11,7 +11,6 @@
<file>widgets/terminal/Terminal.qml</file>
<file>widgets/views/SelectionBar.qml</file>
<file>widgets/views/BrowserMenu.qml</file>
<file>widgets_templates/NewDialog.qml</file>
<file>widgets/views/DetailsDrawer.qml</file>
<file>widgets/views/Previewer/AudioPreview.qml</file>
<file>widgets/views/Previewer/ImagePreview.qml</file>
......
import QtQuick 2.9
import QtQuick.Controls 2.2
import org.kde.kirigami 2.2 as Kirigami
Dialog
{
width: Kirigami.Units.devicePixelRatio * 200
height: width * 0.7
standardButtons: Dialog.Save | Dialog.Cancel
x: (parent.width - width) / 2
y: (parent.height - height) / 2
parent: ApplicationWindow.overlay
modal: true
margins: 1
padding: space.tiny*0.5
signal finished(string text)
property alias text : entryText.text
TextField
{
id: entryText
anchors.centerIn: parent
placeholderText: title
onAccepted:
{
finished(entryText.text)
clear()
}
}
onAccepted:
{
finished(entryText.text)
entryText.clear()
}
onRejected: entryText.clear()
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment