diff options
Diffstat (limited to 'src/libgui/toplevel.cpp')
-rw-r--r-- | src/libgui/toplevel.cpp | 122 |
1 files changed, 61 insertions, 61 deletions
diff --git a/src/libgui/toplevel.cpp b/src/libgui/toplevel.cpp index 55eac3f..61739e0 100644 --- a/src/libgui/toplevel.cpp +++ b/src/libgui/toplevel.cpp @@ -179,150 +179,150 @@ MainWindow::MainWindow() // actions // file actions - KAction *a = KStdAction::openNew(TQT_TQOBJECT(this), TQT_SLOT(newSourceFile()), actionCollection()); + TDEAction *a = KStdAction::openNew(TQT_TQOBJECT(this), TQT_SLOT(newSourceFile()), actionCollection()); a->setText(i18n("&New Source File...")); - (void)new KAction(i18n("New hex File..."), "filenew", 0, TQT_TQOBJECT(this), TQT_SLOT(newHexFile()), + (void)new TDEAction(i18n("New hex File..."), "filenew", 0, TQT_TQOBJECT(this), TQT_SLOT(newHexFile()), actionCollection(), "file_new_hex"); KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(openFile()), actionCollection()); - KRecentFilesAction *recent = KStdAction::openRecent(TQT_TQOBJECT(this), TQT_SLOT(openRecentFile(const KURL &)), actionCollection()); + TDERecentFilesAction *recent = KStdAction::openRecent(TQT_TQOBJECT(this), TQT_SLOT(openRecentFile(const KURL &)), actionCollection()); recent->setMaxItems(20); recent->loadEntries(kapp->config(), "recent-files"); - (void)new KAction(i18n("Save All"), 0, 0, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(saveAllFiles()), + (void)new TDEAction(i18n("Save All"), 0, 0, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(saveAllFiles()), actionCollection(), "file_save_all"); KStdAction::close(TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(closeCurrentEditor()), actionCollection()); - (void)new KAction(i18n("C&lose All"), 0, 0, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(closeAllEditors()), + (void)new TDEAction(i18n("C&lose All"), 0, 0, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(closeAllEditors()), actionCollection(), "file_close_all"); - (void)new KAction(i18n("Close All Others"), 0, 0, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(closeAllOtherEditors()), + (void)new TDEAction(i18n("Close All Others"), 0, 0, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(closeAllOtherEditors()), actionCollection(), "file_closeother"); KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection()); // edit actions // view actions - (void)new KAction(i18n("Back"), "back", TQt::ALT + TQt::Key_Left, + (void)new TDEAction(i18n("Back"), "back", TQt::ALT + TQt::Key_Left, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(goBack()), actionCollection(), "history_back"); - (void)new KAction(i18n("Forward"), "forward", TQt::ALT + TQt::Key_Right, + (void)new TDEAction(i18n("Forward"), "forward", TQt::ALT + TQt::Key_Right, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(goForward()), actionCollection(), "history_forward"); - (void)new KAction(i18n("Switch to..."), 0, TQt::CTRL + TQt::Key_Slash, + (void)new TDEAction(i18n("Switch to..."), 0, TQt::CTRL + TQt::Key_Slash, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(switchToEditor()), actionCollection(), "file_switchto"); - (void)new KAction(i18n("Switch Header/Implementation"), 0, TQt::SHIFT + TQt::Key_F12, + (void)new TDEAction(i18n("Switch Header/Implementation"), 0, TQt::SHIFT + TQt::Key_F12, TQT_TQOBJECT(Main::_editorManager), TQT_SLOT(switchHeaderImplementation()), actionCollection(), "view_switch_source"); - (void)new KAction(TQString(), 0, 0, + (void)new TDEAction(TQString(), 0, 0, Debugger::manager, TQT_SLOT(toggleBreakpoint()), actionCollection(), "toggle_breakpoint"); - (void)new KAction(TQString(), 0, 0, + (void)new TDEAction(TQString(), 0, 0, Debugger::manager, TQT_SLOT(toggleEnableBreakpoint()), actionCollection(), "enable_breakpoint"); - (void)new KAction(i18n("Show disassembly location"), 0, 0, + (void)new TDEAction(i18n("Show disassembly location"), 0, 0, Debugger::manager, TQT_SLOT(showDisassemblyLocation()), actionCollection(), "show_disassembly_location"); - KActionMenu *toolViewsMenu = new KActionMenu( i18n("Tool Views"), 0, "view_tool_views"); + TDEActionMenu *toolViewsMenu = new TDEActionMenu( i18n("Tool Views"), 0, "view_tool_views"); connect(toolViewsMenu->popupMenu(), TQT_SIGNAL(aboutToShow()), TQT_SLOT(updateToolViewsActions())); actionCollection()->insert(toolViewsMenu); - a = new KAction(i18n("&Reset Layout"), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(resetDockLayout()), actionCollection(), "view_reset_layout"); + a = new TDEAction(i18n("&Reset Layout"), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(resetDockLayout()), actionCollection(), "view_reset_layout"); toolViewsMenu->insert(a); toolViewsMenu->popupMenu()->insertSeparator(); TQValueList<DockData>::iterator it; for(it=_docks.begin(); it!=_docks.end(); ++it) toolViewsMenu->insert((*it).action); // project actions - (void)new KAction(i18n("New Project..."), "piklab_createproject", 0, + (void)new TDEAction(i18n("New Project..."), "piklab_createproject", 0, TQT_TQOBJECT(this), TQT_SLOT(newProject()), actionCollection(), "project_new"); - (void)new KAction(i18n("Open Project..."), "piklab_openproject", 0, + (void)new TDEAction(i18n("Open Project..."), "piklab_openproject", 0, TQT_TQOBJECT(this), TQT_SLOT(openProject()), actionCollection(), "project_open"); - recent = new KRecentFilesAction(i18n("Open Recent Project"), 0, + recent = new TDERecentFilesAction(i18n("Open Recent Project"), 0, TQT_TQOBJECT(this), TQT_SLOT(openRecentProject(const KURL &)), actionCollection(), "project_open_recent"); recent->setMaxItems(20); recent->loadEntries(kapp->config(), "recent-projects"); - (void)new KAction(i18n("Project Options..."), "configure", 0, + (void)new TDEAction(i18n("Project Options..."), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(configureProject()), actionCollection(), "project_options"); - (void)new KAction(i18n("Close Project"), "fileclose", 0, + (void)new TDEAction(i18n("Close Project"), "fileclose", 0, TQT_TQOBJECT(this), TQT_SLOT(closeProject()), actionCollection(), "project_close"); - (void)new KAction(i18n("Add Source File..."), "piklab_addfile", 0, + (void)new TDEAction(i18n("Add Source File..."), "piklab_addfile", 0, TQT_TQOBJECT(Main::_projectManager), TQT_SLOT(insertSourceFiles()), actionCollection(), "project_add_source_file"); - (void)new KAction(i18n("Add Object File..."), "piklab_addfile", 0, + (void)new TDEAction(i18n("Add Object File..."), "piklab_addfile", 0, TQT_TQOBJECT(Main::_projectManager), TQT_SLOT(insertObjectFiles()), actionCollection(), "project_add_object_file"); - (void)new KAction(i18n("Add Current File"), "piklab_addcurrentfile", 0, + (void)new TDEAction(i18n("Add Current File"), "piklab_addcurrentfile", 0, TQT_TQOBJECT(Main::_projectManager), TQT_SLOT(insertCurrentFile()), actionCollection(), "project_add_current_file"); // build actions - (void)new KAction(i18n("&Build Project"), "piklab_compile", TQt::Key_F8, + (void)new TDEAction(i18n("&Build Project"), "piklab_compile", TQt::Key_F8, TQT_TQOBJECT(this), TQT_SLOT(buildProject()), actionCollection(), "build_build_project"); - (void)new KAction(i18n("&Compile File"), 0, TQt::SHIFT + TQt::Key_F8, + (void)new TDEAction(i18n("&Compile File"), 0, TQt::SHIFT + TQt::Key_F8, TQT_TQOBJECT(this), TQT_SLOT(compileFile()), actionCollection(), "build_compile_file"); - (void)new KAction(i18n("Clean"), "trashcan_empty", 0, + (void)new TDEAction(i18n("Clean"), "trashcan_empty", 0, TQT_TQOBJECT(this), TQT_SLOT(cleanBuild()), actionCollection(), "build_clean"); - (void)new KAction(i18n("Stop"), "stop", 0, + (void)new TDEAction(i18n("Stop"), "stop", 0, TQT_TQOBJECT(this), TQT_SLOT(stopBuild()), actionCollection(), "build_stop"); // programmer actions - (void)new KAction(i18n("&Connect"), "connect_creating", 0, + (void)new TDEAction(i18n("&Connect"), "connect_creating", 0, Programmer::manager, TQT_SLOT(connectDevice()), actionCollection(), "prog_connect"); - (void)new KToggleAction(i18n("Device Power"), "piklab_power", 0, + (void)new TDEToggleAction(i18n("Device Power"), "piklab_power", 0, Programmer::manager, TQT_SLOT(toggleDevicePower()), actionCollection(), "prog_power"); - (void)new KAction(i18n("&Disconnect"), "connect_no", 0, + (void)new TDEAction(i18n("&Disconnect"), "connect_no", 0, Programmer::manager, TQT_SLOT(disconnectDevice()), actionCollection(), "prog_disconnect"); - (void)new KAction(i18n("&Program"), "piklab_burnchip", TQt::SHIFT + TQt::Key_F5, + (void)new TDEAction(i18n("&Program"), "piklab_burnchip", TQt::SHIFT + TQt::Key_F5, TQT_TQOBJECT(this), TQT_SLOT(program()), actionCollection(), "prog_program"); - (void)new KAction(i18n("&Verify"), "piklab_verifychip", TQt::SHIFT + TQt::Key_F6, + (void)new TDEAction(i18n("&Verify"), "piklab_verifychip", TQt::SHIFT + TQt::Key_F6, TQT_TQOBJECT(this), TQT_SLOT(verify()), actionCollection(), "prog_verify"); - (void)new KAction(i18n("&Read"), "piklab_readchip", TQt::SHIFT + TQt::Key_F7, + (void)new TDEAction(i18n("&Read"), "piklab_readchip", TQt::SHIFT + TQt::Key_F7, TQT_TQOBJECT(this), TQT_SLOT(read()), actionCollection(), "prog_read"); - (void)new KAction(i18n("&Erase"), "piklab_erasechip", 0, + (void)new TDEAction(i18n("&Erase"), "piklab_erasechip", 0, TQT_TQOBJECT(this), TQT_SLOT(erase()), actionCollection(), "prog_erase"); - (void)new KAction(i18n("&Blank Check"), "piklab_blankcheck", 0, + (void)new TDEAction(i18n("&Blank Check"), "piklab_blankcheck", 0, TQT_TQOBJECT(this), TQT_SLOT(blankCheck()), actionCollection(), "prog_blank_check"); - (void)new KAction(i18n("&Run"), "launch", TQt::SHIFT + TQt::Key_F9, + (void)new TDEAction(i18n("&Run"), "launch", TQt::SHIFT + TQt::Key_F9, Programmer::manager, TQT_SLOT(run()), actionCollection(), "prog_run"); - (void)new KAction(i18n("&Stop"), "piklab_stop", 0, + (void)new TDEAction(i18n("&Stop"), "piklab_stop", 0, Programmer::manager, TQT_SLOT(halt()), actionCollection(), "prog_stop"); - (void)new KAction(i18n("R&estart"), "piklab_restart", 0, + (void)new TDEAction(i18n("R&estart"), "piklab_restart", 0, Programmer::manager, TQT_SLOT(restart()), actionCollection(), "prog_restart"); - (void)new KAction(i18n("&Advanced..."), 0, 0, + (void)new TDEAction(i18n("&Advanced..."), 0, 0, Programmer::manager , TQT_SLOT(showAdvancedDialog()), actionCollection(), "prog_advanced"); - (void)new KAction(i18n("Settings..."), "configure", 0, + (void)new TDEAction(i18n("Settings..."), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(showProgrammerSettings()), actionCollection(), "prog_settings"); // debugger actions - (void)new KAction(i18n("&Start"), "launch", TQt::SHIFT + TQt::Key_F9, + (void)new TDEAction(i18n("&Start"), "launch", TQt::SHIFT + TQt::Key_F9, Programmer::manager, TQT_SLOT(restart()), actionCollection(), "debug_start"); - (void)new KAction(i18n("&Run"), "piklab_run", TQt::SHIFT + TQt::Key_F9, + (void)new TDEAction(i18n("&Run"), "piklab_run", TQt::SHIFT + TQt::Key_F9, Programmer::manager, TQT_SLOT(run()), actionCollection(), "debug_run"); - (void)new KAction(i18n("&Step"), "piklab_debug_step", 0, + (void)new TDEAction(i18n("&Step"), "piklab_debug_step", 0, Programmer::manager, TQT_SLOT(step()), actionCollection(), "debug_next"); - //(void)new KAction(i18n("Step &In"), "piklab_debug_stepin", + //(void)new TDEAction(i18n("Step &In"), "piklab_debug_stepin", // 0, TQT_TQOBJECT(this), TQT_SLOT(debugStepIn()), actionCollection(), "debug_step_in"); - //(void)new KAction(i18n("Step &Out"), "piklab_debug_stepout", + //(void)new TDEAction(i18n("Step &Out"), "piklab_debug_stepout", // 0, TQT_TQOBJECT(this), TQT_SLOT(debugStepOut()), actionCollection(), "debug_step_out"); - (void)new KAction(i18n("&Break<Translators: it is the verb>", "&Halt"), "piklab_debughalt", 0, + (void)new TDEAction(i18n("&Break<Translators: it is the verb>", "&Halt"), "piklab_debughalt", 0, Programmer::manager, TQT_SLOT(halt()), actionCollection(), "debug_halt"); - (void)new KAction(i18n("&Disconnect/Stop"), "piklab_stop", 0, + (void)new TDEAction(i18n("&Disconnect/Stop"), "piklab_stop", 0, Programmer::manager, TQT_SLOT(disconnectDevice()), actionCollection(), "debug_stop"); - (void)new KAction(i18n("R&eset"), "piklab_restart", 0, + (void)new TDEAction(i18n("R&eset"), "piklab_restart", 0, Programmer::manager, TQT_SLOT(restart()), actionCollection(), "debug_reset"); - (void)new KAction(i18n("Show Program Counter"), "piklab_program_counter", 0, + (void)new TDEAction(i18n("Show Program Counter"), "piklab_program_counter", 0, Debugger::manager, TQT_SLOT(showPC()), actionCollection(), "debug_show_pc"); - (void)new KAction(i18n("Clear All Breakpoints"), "remove", 0, + (void)new TDEAction(i18n("Clear All Breakpoints"), "remove", 0, Debugger::manager, TQT_SLOT(clearBreakpoints()), actionCollection(), "debug_clear_breakpoints"); - (void)new KAction(i18n("Settings..."), "configure", 0, + (void)new TDEAction(i18n("Settings..."), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(showDebuggerSettings()), actionCollection(), "debug_settings"); // tools - (void)new KAction(i18n("&Pikloops..."), 0, 0, + (void)new TDEAction(i18n("&Pikloops..."), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(runPikloops()), actionCollection(), "tools_pikloops"); - (void)new KAction(i18n("&Find Files..."), "find", 0, + (void)new TDEAction(i18n("&Find Files..."), "find", 0, TQT_TQOBJECT(this), TQT_SLOT(runKfind()), actionCollection(), "tools_kfind"); - (void)new KAction(i18n("&Device Information..."), "info", 0, + (void)new TDEAction(i18n("&Device Information..."), "info", 0, TQT_TQOBJECT(this), TQT_SLOT(showDeviceInfo()), actionCollection(), "tools_device_information"); - (void)new KAction(i18n("&Config Generator..."), 0, 0, + (void)new TDEAction(i18n("&Config Generator..."), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(configGenerator()), actionCollection(), "tools_config_generator"); - (void)new KAction(i18n("&Template Generator..."), 0, 0, + (void)new TDEAction(i18n("&Template Generator..."), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(templateGenerator()), actionCollection(), "tools_template_generator"); // settings actions - (void)new KAction(i18n("Configure Toolchains..."), 0, 0, + (void)new TDEAction(i18n("Configure Toolchains..."), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(configureToolchains()), actionCollection(), "options_configure_toolchains"); (void)KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(configure()), actionCollection()); // help - (void)new KAction(i18n("Report Bug..."), "likeback_bug", 0, + (void)new TDEAction(i18n("Report Bug..."), "likeback_bug", 0, TQT_TQOBJECT(LikeBack::instance()), TQT_SLOT(iFoundABug()), actionCollection(), "help_report_bug_piklab"); setupGUI(); @@ -512,8 +512,8 @@ bool MainWindow::queryClose() // save other settings ::PBusyCursor bc; writeDockConfig(kapp->config(), "dock_config"); - static_cast<KRecentFilesAction *>(Main::action("project_open_recent"))->saveEntries(kapp->config(), "recent-projects"); - static_cast<KRecentFilesAction *>(Main::action("file_open_recent"))->saveEntries(kapp->config(), "recent-files"); + static_cast<TDERecentFilesAction *>(Main::action("project_open_recent"))->saveEntries(kapp->config(), "recent-projects"); + static_cast<TDERecentFilesAction *>(Main::action("file_open_recent"))->saveEntries(kapp->config(), "recent-files"); GlobalConfig::writeOpenedProject(Main::project() ? Main::project()->url() : PURL::Url()); if ( Main::project() ) Main::_projectManager->closeProject(); return true; @@ -645,7 +645,7 @@ void MainWindow::updateGUI() Main::action("prog_erase")->setEnabled(isProgrammer && idle); Main::action("prog_blank_check")->setEnabled(isProgrammer && idle); Programmer::State pstate = (Main::programmer() ? Main::programmer()->state() : Programmer::NotConnected); - static_cast<KToggleAction *>(Main::action("prog_power"))->setEnabled(isProgrammer && idle && pstate!=Programmer::NotConnected); + static_cast<TDEToggleAction *>(Main::action("prog_power"))->setEnabled(isProgrammer && idle && pstate!=Programmer::NotConnected); Main::action("prog_disconnect")->setEnabled(isProgrammer && idle && pstate!=Programmer::NotConnected); bool isDebugger = ( Main::programmerGroup().properties() & ::Programmer::Debugger ); bool resetAvailable = ( Main::programmerGroup().properties() & Programmer::CanReleaseReset ); |