mirror of
https://github.com/FunkinCrew/Funkin.git
synced 2024-11-23 08:07:54 -05:00
last modified
This commit is contained in:
parent
6421b5d57d
commit
e44559d056
1 changed files with 8 additions and 0 deletions
|
@ -83,10 +83,18 @@ class ChartEditorWelcomeDialog extends ChartEditorBaseDialog
|
|||
public function addRecentFilePath(state:ChartEditorState, chartPath:String):Void
|
||||
{
|
||||
var linkRecentChart:Link = new Link();
|
||||
|
||||
var fileNamePattern:EReg = new EReg("([^/\\\\]+)$", "");
|
||||
var fileName:String = fileNamePattern.match(chartPath) ? fileNamePattern.matched(1) : chartPath;
|
||||
linkRecentChart.text = fileName;
|
||||
|
||||
linkRecentChart.tooltip = chartPath;
|
||||
|
||||
#if sys
|
||||
var lastModified:String = "Last Modified: " + sys.FileSystem.stat(chartPath).mtime.toString();
|
||||
linkRecentChart.tooltip += "\n" + lastModified;
|
||||
#end
|
||||
|
||||
linkRecentChart.onClick = function(_event) {
|
||||
this.hideDialog(DialogButton.CANCEL);
|
||||
|
||||
|
|
Loading…
Reference in a new issue