Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Open Map Scripts" button #24

Merged
merged 3 commits into from
Sep 13, 2018
Merged

Conversation

garakmon
Copy link
Collaborator

(copy of yenatch/pretmap#70)

Adds a button to open a map's scripts in a the system default text editor.

Should close Issue #4

demo:
Alt text

@huderlem
Copy link
Owner

Rather than using those different commands for different OS's, we should use Qt's built-in functionality:

QString path = QDir::cleanPath(editor->project->root + QDir::separator() + "data/maps/" + editor->map->name + "/scripts.inc");
QDesktopServices::openUrl(QUrl(path));

Plus, the Windows command didn't work for me.

@huderlem huderlem merged commit 4313662 into huderlem:master Sep 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants