| 46 | const SingleApplication::Options opts = SingleApplication::ExcludeAppPath | SingleApplication::ExcludeAppVersion | SingleApplication::SecondaryNotification; |
| 47 | |
| 48 | void parseCommandLine(QCommandLineParser &parser, const QStringList &args) |
| 49 | { |
| 50 | parser.setApplicationDescription("Notepad Next"); |
| 51 | parser.addHelpOption(); |
| 52 | parser.addVersionOption(); |
| 53 | |
| 54 | parser.addPositionalArgument("files", "Files to open."); |
| 55 | |
| 56 | parser.addOptions({ |
| 57 | {"translation", "Overrides the system default translation.", "translation"}, |
| 58 | {"reset-settings", "Resets all application settings."}, |
| 59 | {"n", "Places the cursor on the line number for the first file specified", "line number"}, |
| 60 | {"workspace", "Opens the specified folder as a workspace", "workspace path"} |
| 61 | }); |
| 62 | |
| 63 | parser.process(args); |
| 64 | } |
| 65 | |
| 66 | static QString toLocalFileName(const QString file) |
| 67 | { |
no outgoing calls
no test coverage detected