ResetInit.js 1.2 KB

123456789101112131415161718192021222324252627282930313233343536
  1. // include("scripts/EAction.js");
  2. // function init(basePath) {
  3. // // make sure the reset toolbar comes first:
  4. // var tb = EAction.getToolBar(qsTranslate("Reset", "Reset"), "ResetToolBar");
  5. // var action = new RGuiAction(qsTranslate("Reset", "&Reset / Idle"), RMainWindowQt.getMainWindow());
  6. // action.setRequiresDocument(true);
  7. // action.setScriptFile(basePath + "/Reset.js");
  8. // action.setIcon(basePath + "/Reset.svg");
  9. // // workaround for Linux/Qt bug
  10. // // input of @ in command line not possible on German keyboard where
  11. // // Alt-Q is used to enter @:
  12. // var useShortcut = true;
  13. // if (RS.getSystemId()==="linux") {
  14. // var locale = RSettings.getLocale();
  15. // if (locale.length>=2) {
  16. // if (locale.substring(0,2)==="de") {
  17. // useShortcut = false;
  18. // }
  19. // }
  20. // }
  21. // if (useShortcut) {
  22. // action.setDefaultShortcut(new QKeySequence("q,q"));
  23. // }
  24. // action.setDefaultCommands(["reset", "qq"]);
  25. // action.setGroupSortOrder(2700);
  26. // action.setSortOrder(200);
  27. // action.setWidgetNames(["EditMenu", "ResetToolBar"]);
  28. // RSettings.setValue("Reset/VisibleInToolBar", true);
  29. // }