void DXmlGuiWindow::createSettingsActions() { d->showMenuBarAction = KStandardAction::showMenubar(this, SLOT(slotShowMenuBar()), actionCollection()); KStandardAction::configureNotifications(this, SLOT(slotConfNotifications()), actionCollection()); KStandardAction::keyBindings(this, SLOT(slotEditKeys()), actionCollection()); KStandardAction::preferences(this, SLOT(slotSetup()), actionCollection()); KStandardAction::configureToolbars(this, SLOT(slotConfToolbars()), actionCollection()); }
void MainWindow::setupActions() { //file menu KStdAction::openNew(this, SLOT(slotNewFile()), actionCollection()); KStdAction::open(this, SLOT(slotOpenFile()), actionCollection()); m_actionRecent = KStdAction::openRecent(this, SLOT(slotFileRecent(const KURL&)), actionCollection()); m_actionRecent->loadEntries(kapp->config());//,"Recent Files"); KStdAction::save(this, SLOT(slotSaveCurrentFile()), actionCollection()); KStdAction::saveAs(this, SLOT(slotSaveCurrentFileAs()), actionCollection()); KStdAction::close(this, SLOT(slotCloseFile()), actionCollection()); (void)new KAction(i18n("Close All"), 0, this, SLOT(slotCloseAllFiles()), actionCollection(), "file_close_all"); KStdAction::quit(this, SLOT(slotQuit()), actionCollection()); KStdAction::keyBindings(this, SLOT(slotEditKeys()), actionCollection()); KStdAction::configureToolbars(this, SLOT(slotEditToolbars()), actionCollection()); KStdAction::preferences(this, SLOT(slotShowSettings()), actionCollection(), "settings_gpteditor"); (void)new KAction(i18n("Compile"), "make_kdevelop", "F10", m_debugger_manager, SLOT(slotCompileApplication()), actionCollection(), "compile_application"); (void)new KAction(i18n("Run"), "gear", "F9", m_debugger_manager, SLOT(slotRunApplication()), actionCollection(), "run_application"); (void)new KAction(i18n("Start Debug"), "dbgstart", "F5", m_debugger_manager, SLOT(slotDebugStart()), actionCollection(), "debug_start"); (void)new KAction(i18n("Stop Debug"), "stop", "Escape", m_debugger_manager, SLOT(slotDebugStop()), actionCollection(), "debug_stop"); (void)new KAction(i18n("Step Over"), "dbgnext", "F6", m_debugger_manager, SLOT(slotDebugStepOver()), actionCollection(), "debug_step_over"); (void)new KAction(i18n("Step Into"), "dbgstep", "F7", m_debugger_manager, SLOT(slotDebugStepInto()), actionCollection(), "debug_step_into"); (void)new KAction(i18n("Step Out"), "dbgstepout", "F8", m_debugger_manager, SLOT(slotDebugStepOut()), actionCollection(), "debug_step_out"); // (void)new KAction(i18n("Profile (DBG only)"), "math_sum", "Alt+P", m_debugger_manager, // SLOT(slotProfile()), actionCollection(), "script_profile"); (void)new KAction(i18n("Toggle Breakpoint"), "activebreakpoint", "Alt+B", m_debugger_manager, SLOT(slotDebugToggleBp()), actionCollection(), "debug_toggle_bp"); // (void)new KAction("", "math_brace", 0, m_tabEditor, // SLOT(slotAddWatch()), actionCollection(), "editor_add_watch"); // Editor default action setStandardToolBarMenuEnabled(true); }
void MainWindow::setupActions() { //file menu KStdAction::open(this, SLOT(slotOpenFile()), actionCollection()); m_actionRecent = KStdAction::openRecent(this, SLOT(slotFileRecent(const KURL&)), actionCollection()); m_actionRecent->loadEntries(kapp->config());//,"Recent Files"); KStdAction::close(this, SLOT(slotCloseFile()), actionCollection()); (void)new KAction(i18n("Close All"), 0, this, SLOT(slotCloseAllFiles()), actionCollection(), "file_close_all"); KStdAction::quit(this, SLOT(slotQuit()), actionCollection()); KStdAction::keyBindings(this, SLOT(slotEditKeys()), actionCollection()); KStdAction::configureToolbars(this, SLOT(slotEditToolbars()), actionCollection()); KStdAction::preferences(this, SLOT(slotShowSettings()), actionCollection(), "settings_protoeditor"); m_siteAction = new KSelectAction("Site", 0, actionCollection(), "site_selection"); connect(m_siteAction, SIGNAL(activated(const QString&)), ProtoeditorSettings::self(), SLOT(slotCurrentSiteChanged(const QString&))); m_defaultScriptAction = new KSelectAction("Default script", 0, actionCollection(), "default_script"); QStringList l; l << "Site Script" << "Active Script"; m_defaultScriptAction->setItems(l); m_defaultScriptAction->setCurrentItem(0); // connect(m_defaultScriptAction, SIGNAL(activated(int)), // this, SLOT(slotDefaultScriptChanged(int))); // (void)new KAction(i18n("&Run"), "gear", "F9", m_debugger_manager, // SLOT(slotDebugStart()), actionCollection(), "script_run_current_script"); (void)new KAction(i18n("Start Debug"), "dbgstart", "F5", m_debugger_manager, SLOT(slotDebugStart()), actionCollection(), "debug_start"); (void)new KAction(i18n("Stop Debug"), "stop", "Escape", m_debugger_manager, SLOT(slotDebugStop()), actionCollection(), "debug_stop"); (void)new KAction(i18n("Step Over"), "dbgnext", "F6", m_debugger_manager, SLOT(slotDebugStepOver()), actionCollection(), "debug_step_over"); (void)new KAction(i18n("Step Into"), "dbgstep", "F7", m_debugger_manager, SLOT(slotDebugStepInto()), actionCollection(), "debug_step_into"); (void)new KAction(i18n("Step Out"), "dbgstepout", "F8", m_debugger_manager, SLOT(slotDebugStepOut()), actionCollection(), "debug_step_out"); (void)new KAction(i18n("Profile"), "math_sum", "Alt+P", m_debugger_manager, SLOT(slotProfile()), actionCollection(), "script_profile"); (void)new KAction(i18n("Toggle Breakpoint"), "activebreakpoint", "Alt+B", m_debugger_manager, SLOT(slotDebugToggleBp()), actionCollection(), "debug_toggle_bp"); (void)new KAction("", "math_brace", 0, m_tabEditor, SLOT(slotAddWatch()), actionCollection(), "editor_add_watch"); setStandardToolBarMenuEnabled(true); }