mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-07-24 12:07:19 +02:00
[ui] better UI Components split + improvements
* add WorkspaceView that contains Meshroom main modules (ImageGallery, 2D/3D viewer) * add Panel component to standardize UI modules layout * ImageGallery: * add images basename on image delegates * add explanatory placeholder when no image has been added to the reconstruction yet
This commit is contained in:
parent
e5acd916dc
commit
8d8bf0be5e
5 changed files with 387 additions and 190 deletions
17
meshroom/ui/qml/filepath.js
Normal file
17
meshroom/ui/qml/filepath.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
/* Utility functions to manipulate file paths */
|
||||
|
||||
/// Returns the directory name of the given path.
|
||||
function dirname(path) {
|
||||
return path.substring(0, path.lastIndexOf('/'))
|
||||
}
|
||||
|
||||
/// Returns the basename (file.extension) of the given path.
|
||||
function basename(path) {
|
||||
return path.substring(path.lastIndexOf('/') + 1, path.length)
|
||||
}
|
||||
|
||||
/// Return the extension (prefixed by a '.') of the given path.
|
||||
function extension(path) {
|
||||
var dot_pos = path.lastIndexOf('.');
|
||||
return dot_pos > -1 ? path.substring(dot_pos, path.length) : ""
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue