58 lines
1.6 KiB
QML
58 lines
1.6 KiB
QML
import QtQuick
|
|
import QtQuick.Controls
|
|
import QtQuick.Layouts
|
|
|
|
import clide.module 1.0
|
|
|
|
SplitView {
|
|
Layout.fillHeight: true
|
|
Layout.fillWidth: true
|
|
anchors.fill: parent
|
|
|
|
// Customized handle to drag between the Navigation and the Editor.
|
|
handle: Rectangle {
|
|
border.color: SplitHandle.pressed ? RustColors.pressed : SplitHandle.hovered ? RustColors.hovered : RustColors.gutter
|
|
color: SplitHandle.pressed ? RustColors.pressed : SplitHandle.hovered ? RustColors.hovered : RustColors.gutter
|
|
implicitWidth: 8
|
|
radius: 2.5
|
|
|
|
// Execute these behaviors when the color is changed.
|
|
Behavior on color {
|
|
ColorAnimation {
|
|
duration: 400
|
|
}
|
|
}
|
|
}
|
|
|
|
Rectangle {
|
|
id: navigationView
|
|
|
|
SplitView.fillHeight: true
|
|
SplitView.preferredWidth: 200
|
|
color: RustColors.explorer_background
|
|
|
|
StackLayout {
|
|
anchors.fill: parent
|
|
|
|
// Shows the help text.
|
|
TextArea {
|
|
placeholderText: qsTr("File system view placeholder")
|
|
placeholderTextColor: "white"
|
|
readOnly: true
|
|
wrapMode: TextArea.Wrap
|
|
}
|
|
|
|
// TODO: Shows the files on the file system.
|
|
// ClideTreeView {
|
|
// id: fileSystemView
|
|
// color: Colors.surface1
|
|
// onFileClicked: path => root.currentFilePath = path
|
|
// }
|
|
}
|
|
}
|
|
ClideEditor {
|
|
// Initialize using the Default trait in Rust QML singleton FileSystem.
|
|
filePath: FileSystem.filePath
|
|
}
|
|
}
|