diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-12 01:36:19 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-12 01:36:19 +0000 |
commit | 99a2774ca6f1cab334de5d43fe36fc44ae889a4c (patch) | |
tree | eff34cf0762227f6baf2a93e8fef48d4bed2651c /umbrello/umbrello/uml.cpp | |
parent | 1c104292188541106338d4940b0f04beeb4301a0 (diff) | |
download | tdesdk-99a2774ca6f1cab334de5d43fe36fc44ae889a4c.tar.gz tdesdk-99a2774ca6f1cab334de5d43fe36fc44ae889a4c.zip |
TQt4 convert kdesdk
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1236185 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'umbrello/umbrello/uml.cpp')
-rw-r--r-- | umbrello/umbrello/uml.cpp | 174 |
1 files changed, 87 insertions, 87 deletions
diff --git a/umbrello/umbrello/uml.cpp b/umbrello/umbrello/uml.cpp index e6a87cfd..13608f3c 100644 --- a/umbrello/umbrello/uml.cpp +++ b/umbrello/umbrello/uml.cpp @@ -55,7 +55,7 @@ #include "umlviewlist.h" #include "worktoolbar.h" #ifdef HAVE_DOT -# include "autolayout/autolayoutdlg.h" //dimitri +# include "autotqlayout/autotqlayoutdlg.h" //dimitri #endif #include "model_utils.h" #include "clipboard/umlclipboard.h" @@ -160,43 +160,43 @@ UMLApp* UMLApp::app() } void UMLApp::initActions() { - fileNew = KStdAction::openNew(this, TQT_SLOT(slotFileNew()), actionCollection()); - fileOpen = KStdAction::open(this, TQT_SLOT(slotFileOpen()), actionCollection()); - fileOpenRecent = KStdAction::openRecent(this, TQT_SLOT(slotFileOpenRecent(const KURL&)), actionCollection()); - fileSave = KStdAction::save(this, TQT_SLOT(slotFileSave()), actionCollection()); - fileSaveAs = KStdAction::saveAs(this, TQT_SLOT(slotFileSaveAs()), actionCollection()); - fileClose = KStdAction::close(this, TQT_SLOT(slotFileClose()), actionCollection()); - filePrint = KStdAction::print(this, TQT_SLOT(slotFilePrint()), actionCollection()); - fileQuit = KStdAction::quit(this, TQT_SLOT(slotFileQuit()), actionCollection()); - editUndo = KStdAction::undo(this, TQT_SLOT(slotEditUndo()), actionCollection()); - editRedo = KStdAction::redo(this, TQT_SLOT(slotEditRedo()), actionCollection()); - editCut = KStdAction::cut(this, TQT_SLOT(slotEditCut()), actionCollection()); - editCopy = KStdAction::copy(this, TQT_SLOT(slotEditCopy()), actionCollection()); - editPaste = KStdAction::paste(this, TQT_SLOT(slotEditPaste()), actionCollection()); + fileNew = KStdAction::openNew(TQT_TQOBJECT(this), TQT_SLOT(slotFileNew()), actionCollection()); + fileOpen = KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(slotFileOpen()), actionCollection()); + fileOpenRecent = KStdAction::openRecent(TQT_TQOBJECT(this), TQT_SLOT(slotFileOpenRecent(const KURL&)), actionCollection()); + fileSave = KStdAction::save(TQT_TQOBJECT(this), TQT_SLOT(slotFileSave()), actionCollection()); + fileSaveAs = KStdAction::saveAs(TQT_TQOBJECT(this), TQT_SLOT(slotFileSaveAs()), actionCollection()); + fileClose = KStdAction::close(TQT_TQOBJECT(this), TQT_SLOT(slotFileClose()), actionCollection()); + filePrint = KStdAction::print(TQT_TQOBJECT(this), TQT_SLOT(slotFilePrint()), actionCollection()); + fileQuit = KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(slotFileQuit()), actionCollection()); + editUndo = KStdAction::undo(TQT_TQOBJECT(this), TQT_SLOT(slotEditUndo()), actionCollection()); + editRedo = KStdAction::redo(TQT_TQOBJECT(this), TQT_SLOT(slotEditRedo()), actionCollection()); + editCut = KStdAction::cut(TQT_TQOBJECT(this), TQT_SLOT(slotEditCut()), actionCollection()); + editCopy = KStdAction::copy(TQT_TQOBJECT(this), TQT_SLOT(slotEditCopy()), actionCollection()); + editPaste = KStdAction::paste(TQT_TQOBJECT(this), TQT_SLOT(slotEditPaste()), actionCollection()); createStandardStatusBarAction(); setStandardToolBarMenuEnabled(true); - selectAll = KStdAction::selectAll(this, TQT_SLOT( slotSelectAll() ), actionCollection()); + selectAll = KStdAction::selectAll(TQT_TQOBJECT(this), TQT_SLOT( slotSelectAll() ), actionCollection()); fileExportDocbook = new KAction(i18n("&Export model to DocBook"), 0, - this, TQT_SLOT( slotFileExportDocbook() ), + TQT_TQOBJECT(this), TQT_SLOT( slotFileExportDocbook() ), actionCollection(), "file_export_docbook"); fileExportXhtml = new KAction(i18n("&Export model to XHTML"), 0, - this, TQT_SLOT( slotFileExportXhtml() ), + TQT_TQOBJECT(this), TQT_SLOT( slotFileExportXhtml() ), actionCollection(), "file_export_xhtml"); - classWizard = new KAction(i18n("&New Class Wizard..."),0,this,TQT_SLOT(slotClassWizard()), + classWizard = new KAction(i18n("&New Class Wizard..."),0,TQT_TQOBJECT(this),TQT_SLOT(slotClassWizard()), actionCollection(),"class_wizard"); - new KAction(i18n("&Add Default Datatypes for Active Language"), 0, this, + new KAction(i18n("&Add Default Datatypes for Active Language"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAddDefaultDatatypes()), actionCollection(), "create_default_datatypes"); - preferences = KStdAction::preferences(this, TQT_SLOT( slotPrefs() ), actionCollection()); + preferences = KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT( slotPrefs() ), actionCollection()); - genWizard = new KAction(i18n("&Code Generation Wizard..."),0,this,TQT_SLOT(generationWizard()), + genWizard = new KAction(i18n("&Code Generation Wizard..."),0,TQT_TQOBJECT(this),TQT_SLOT(generationWizard()), actionCollection(),"generation_wizard"); - genAll = new KAction(i18n("&Generate All Code"),0,this,TQT_SLOT(generateAllCode()), + genAll = new KAction(i18n("&Generate All Code"),0,TQT_TQOBJECT(this),TQT_SLOT(generateAllCode()), actionCollection(),"generate_all"); importClasses = new KAction(i18n("&Import Classes..."), SmallIconSet("source_cpp"), 0, - this,TQT_SLOT(slotImportClasses()), actionCollection(),"import_class"); + TQT_TQOBJECT(this),TQT_SLOT(slotImportClasses()), actionCollection(),"import_class"); fileNew->setToolTip(i18n("Creates a new document")); fileOpen->setToolTip(i18n("Opens an existing document")); @@ -215,63 +215,63 @@ void UMLApp::initActions() { deleteSelectedWidget = new KAction( i18n("Delete &Selected"), SmallIconSet("editdelete"), - KShortcut(Qt::Key_Delete), this, + KShortcut(TQt::Key_Delete), TQT_TQOBJECT(this), TQT_SLOT( slotDeleteSelectedWidget() ), actionCollection(), "delete_selected" ); // The different views newDiagram = new KActionMenu(0, SmallIconSet("filenew"), actionCollection(), "new_view"); classDiagram = new KAction( i18n( "&Class Diagram..." ), SmallIconSet("umbrello_diagram_class"), 0, - this, TQT_SLOT( slotClassDiagram() ), actionCollection(), "new_class_diagram" ); + TQT_TQOBJECT(this), TQT_SLOT( slotClassDiagram() ), actionCollection(), "new_class_diagram" ); #if defined (HAVE_DOT) - autolayout = new KAction(i18n("&Autolayout..."),0,0,this,TQT_SLOT(slotAutolayout()), - actionCollection(),"autolayout"); + autotqlayout = new KAction(i18n("&Autotqlayout..."),0,0,TQT_TQOBJECT(this),TQT_SLOT(slotAutotqlayout()), + actionCollection(),"autotqlayout"); #endif sequenceDiagram= new KAction( i18n( "&Sequence Diagram..." ), SmallIconSet("umbrello_diagram_sequence"), 0, - this, TQT_SLOT( slotSequenceDiagram() ), actionCollection(), "new_sequence_diagram" ); + TQT_TQOBJECT(this), TQT_SLOT( slotSequenceDiagram() ), actionCollection(), "new_sequence_diagram" ); collaborationDiagram = new KAction( i18n( "C&ollaboration Diagram..." ), SmallIconSet("umbrello_diagram_collaboration"), 0, - this, TQT_SLOT( slotCollaborationDiagram() ), actionCollection(), "new_collaboration_diagram" ); + TQT_TQOBJECT(this), TQT_SLOT( slotCollaborationDiagram() ), actionCollection(), "new_collaboration_diagram" ); useCaseDiagram= new KAction( i18n( "&Use Case Diagram..." ), SmallIconSet("umbrello_diagram_usecase"), 0, - this, TQT_SLOT( slotUseCaseDiagram() ), actionCollection(), "new_use_case_diagram" ); + TQT_TQOBJECT(this), TQT_SLOT( slotUseCaseDiagram() ), actionCollection(), "new_use_case_diagram" ); stateDiagram= new KAction( i18n( "S&tate Diagram..." ), SmallIconSet("umbrello_diagram_state"), 0, - this, TQT_SLOT( slotStateDiagram() ), actionCollection(), "new_state_diagram" ); + TQT_TQOBJECT(this), TQT_SLOT( slotStateDiagram() ), actionCollection(), "new_state_diagram" ); activityDiagram= new KAction( i18n( "&Activity Diagram..." ), SmallIconSet("umbrello_diagram_activity"), 0, - this, TQT_SLOT( slotActivityDiagram() ), actionCollection(), "new_activity_diagram" ); + TQT_TQOBJECT(this), TQT_SLOT( slotActivityDiagram() ), actionCollection(), "new_activity_diagram" ); componentDiagram = new KAction( i18n("Co&mponent Diagram..."), SmallIconSet("umbrello_diagram_component"), 0, - this, TQT_SLOT( slotComponentDiagram() ), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT( slotComponentDiagram() ), actionCollection(), "new_component_diagram" ); deploymentDiagram = new KAction( i18n("&Deployment Diagram..."), SmallIconSet("umbrello_diagram_deployment"), 0, - this, TQT_SLOT( slotDeploymentDiagram() ), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT( slotDeploymentDiagram() ), actionCollection(), "new_deployment_diagram" ); entityRelationshipDiagram = new KAction( i18n("&Entity Relationship Diagram..."), SmallIconSet("umbrello_diagram_entityrelationship"), 0, - this, TQT_SLOT( slotEntityRelationshipDiagram() ), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT( slotEntityRelationshipDiagram() ), actionCollection(), "new_entityrelationship_diagram" ); viewClearDiagram = new KAction(i18n("&Clear Diagram"), SmallIconSet("editclear"), 0, - this, TQT_SLOT( slotCurrentViewClearDiagram() ), actionCollection(), "view_clear_diagram"); + TQT_TQOBJECT(this), TQT_SLOT( slotCurrentViewClearDiagram() ), actionCollection(), "view_clear_diagram"); viewSnapToGrid = new KToggleAction(i18n("&Snap to Grid"), 0, - this, TQT_SLOT( slotCurrentViewToggleSnapToGrid() ), actionCollection(), "view_snap_to_grid"); + TQT_TQOBJECT(this), TQT_SLOT( slotCurrentViewToggleSnapToGrid() ), actionCollection(), "view_snap_to_grid"); viewShowGrid = new KToggleAction(i18n("S&how Grid"), 0, - this, TQT_SLOT( slotCurrentViewToggleShowGrid() ), actionCollection(), "view_show_grid"); + TQT_TQOBJECT(this), TQT_SLOT( slotCurrentViewToggleShowGrid() ), actionCollection(), "view_show_grid"); #if (KDE_VERSION_MINOR>=3) && (KDE_VERSION_MAJOR>=3) viewShowGrid->setCheckedState(i18n("&Hide Grid")); #endif deleteDiagram = new KAction(i18n("&Delete"), SmallIconSet("editdelete"), 0, - this, TQT_SLOT( slotDeleteDiagram() ), actionCollection(), "view_delete"); + TQT_TQOBJECT(this), TQT_SLOT( slotDeleteDiagram() ), actionCollection(), "view_delete"); viewExportImage = new KAction(i18n("&Export as Picture..."), SmallIconSet("image"), 0, - this, TQT_SLOT( slotCurrentViewExportImage() ), actionCollection(), "view_export_image"); + TQT_TQOBJECT(this), TQT_SLOT( slotCurrentViewExportImage() ), actionCollection(), "view_export_image"); viewExportImageAll = new KAction(i18n("Export &All Diagrams as Pictures..."), SmallIconSet("image"), 0, - this, TQT_SLOT( slotAllViewsExportImage() ), actionCollection(), "view_export_image_all"); + TQT_TQOBJECT(this), TQT_SLOT( slotAllViewsExportImage() ), actionCollection(), "view_export_image_all"); viewProperties = new KAction(i18n("&Properties"), SmallIconSet("info"), 0, - this, TQT_SLOT( slotCurrentViewProperties() ), actionCollection(), "view_properties"); + TQT_TQOBJECT(this), TQT_SLOT( slotCurrentViewProperties() ), actionCollection(), "view_properties"); viewSnapToGrid->setChecked(false); viewShowGrid->setChecked(false); @@ -284,35 +284,35 @@ void UMLApp::initActions() { viewProperties->setEnabled(false); zoomAction = new KPlayerPopupSliderAction(i18n("&Zoom Slider"), "viewmag", Key_F9, - this, TQT_SLOT(slotZoomSliderMoved(int)), + TQT_TQOBJECT(this), TQT_SLOT(slotZoomSliderMoved(int)), actionCollection(), "popup_zoom"); zoom100Action = new KAction(i18n( "Z&oom to 100%" ), "viewmag1", 0, - this, TQT_SLOT( slotZoom100() ), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT( slotZoom100() ), actionCollection(), "zoom100"); - KStdAction::tipOfDay( this, TQT_SLOT( tipOfTheDay() ), actionCollection() ); + KStdAction::tipOfDay( TQT_TQOBJECT(this), TQT_SLOT( tipOfTheDay() ), actionCollection() ); TQString moveTabLeftString = i18n("&Move Tab Left"); TQString moveTabRightString = i18n("&Move Tab Right"); moveTabLeft = new KAction(TQApplication::reverseLayout() ? moveTabRightString : moveTabLeftString, TQApplication::reverseLayout() ? "forward" : "back", - TQApplication::reverseLayout() ? Qt::CTRL+Qt::SHIFT+Qt::Key_Right : Qt::CTRL+Qt::SHIFT+Qt::Key_Left, - this, TQT_SLOT(slotMoveTabLeft()), actionCollection(), + TQApplication::reverseLayout() ? TQt::CTRL+TQt::SHIFT+TQt::Key_Right : TQt::CTRL+TQt::SHIFT+TQt::Key_Left, + TQT_TQOBJECT(this), TQT_SLOT(slotMoveTabLeft()), actionCollection(), "move_tab_left"); moveTabRight = new KAction(TQApplication::reverseLayout() ? moveTabLeftString : moveTabRightString, TQApplication::reverseLayout() ? "back" : "forward", - TQApplication::reverseLayout() ? Qt::CTRL+Qt::SHIFT+Qt::Key_Left : Qt::CTRL+Qt::SHIFT+Qt::Key_Right, - this, TQT_SLOT(slotMoveTabRight()), actionCollection(), + TQApplication::reverseLayout() ? TQt::CTRL+TQt::SHIFT+TQt::Key_Left : TQt::CTRL+TQt::SHIFT+TQt::Key_Right, + TQT_TQOBJECT(this), TQT_SLOT(slotMoveTabRight()), actionCollection(), "move_tab_right"); TQString selectTabLeftString = i18n("Select Diagram on Left"); TQString selectTabRightString = i18n("Select Diagram on Right"); changeTabLeft = new KAction(TQApplication::reverseLayout() ? selectTabRightString : selectTabLeftString, - TQApplication::reverseLayout() ? Qt::SHIFT+Qt::Key_Right : Qt::SHIFT+Qt::Key_Left, - this, TQT_SLOT(slotChangeTabLeft()), actionCollection(), "previous_tab"); + TQApplication::reverseLayout() ? TQt::SHIFT+TQt::Key_Right : TQt::SHIFT+TQt::Key_Left, + TQT_TQOBJECT(this), TQT_SLOT(slotChangeTabLeft()), actionCollection(), "previous_tab"); changeTabRight = new KAction(TQApplication::reverseLayout() ? selectTabLeftString : selectTabRightString, - TQApplication::reverseLayout() ? Qt::SHIFT+Qt::Key_Left : Qt::SHIFT+Qt::Key_Right, - this, TQT_SLOT(slotChangeTabRight()), actionCollection(), "next_tab"); + TQApplication::reverseLayout() ? TQt::SHIFT+TQt::Key_Left : TQt::SHIFT+TQt::Key_Right, + TQT_TQOBJECT(this), TQT_SLOT(slotChangeTabRight()), actionCollection(), "next_tab"); initStatusBar(); //call this here because the statusBar is shown/hidden by setupGUI() @@ -374,7 +374,7 @@ void UMLApp::setupZoomMenu() { void UMLApp::initStatusBar() { m_statusLabel = new KStatusBarLabel( i18n("Ready."), 0, statusBar() ); - m_statusLabel->setFixedHeight( m_statusLabel->sizeHint().height() ); + m_statusLabel->setFixedHeight( m_statusLabel->tqsizeHint().height() ); m_statusLabel->setFrameStyle( TQFrame::NoFrame | TQFrame::Plain ); m_statusLabel->setMargin( 0 ); @@ -382,7 +382,7 @@ void UMLApp::initStatusBar() { statusBar()->addWidget( m_statusLabel, 1, false ); - m_statusLabel->setAlignment(Qt::AlignLeft|Qt::AlignVCenter); + m_statusLabel->tqsetAlignment(TQt::AlignLeft|TQt::AlignVCenter); connect(m_doc, TQT_SIGNAL( sigWriteToStatusBar(const TQString &) ), this, TQT_SLOT( slotStatusMsg(const TQString &) )); } @@ -392,11 +392,11 @@ void UMLApp::initView() { m_view = NULL; toolsbar = new WorkToolBar(this, ""); toolsbar->setLabel(i18n("Diagram Toolbar")); - addToolBar(toolsbar, Qt::DockTop, false); + addToolBar(toolsbar, TQt::DockTop, false); m_alignToolBar = new AlignToolBar(this, ""); m_alignToolBar->setLabel(i18n("Alignment Toolbar")); - addToolBar(m_alignToolBar, Qt::DockTop, false); + addToolBar(m_alignToolBar, TQt::DockTop, false); m_mainDock = createDockWidget("maindock", 0L, 0L, "main dock"); m_newSessionButton = NULL; @@ -583,8 +583,8 @@ void UMLApp::readOptions() { fileOpenRecent->loadEntries(m_config,"Recent Files"); m_config->setGroup("General Options"); setImageMimeType(m_config->readEntry("imageMimeType","image/png")); - TQSize tmpQSize(630,460); - resize( m_config->readSizeEntry("Geometry", & tmpQSize) ); + TQSize tmpTQSize(630,460); + resize( m_config->readSizeEntry("Geometry", & tmpTQSize) ); } void UMLApp::saveProperties(KConfig *_config) { @@ -737,7 +737,7 @@ bool UMLApp::slotFileSaveAs() TQDir d = url.path(-1); if(TQFile::exists(d.path())) { - int want_save = KMessageBox::warningContinueCancel(this, i18n("The file %1 exists.\nDo you wish to overwrite it?").arg(url.path()), i18n("Warning"), i18n("Overwrite")); + int want_save = KMessageBox::warningContinueCancel(this, i18n("The file %1 exists.\nDo you wish to overwrite it?").tqarg(url.path()), i18n("Warning"), i18n("Overwrite")); if(want_save == KMessageBox::Continue) cont = false; } else @@ -776,7 +776,7 @@ void UMLApp::slotFilePrint() DiagramPrintPage * selectPage = new DiagramPrintPage(0, m_doc); printer.addDialogPage(selectPage); TQString msg; - if (printer.setup(this, i18n("Print %1").arg(m_doc->URL().prettyURL()))) { + if (printer.setup(this, i18n("Print %1").tqarg(m_doc->URL().prettyURL()))) { m_doc -> print(&printer); } @@ -842,7 +842,7 @@ void UMLApp::slotEditCopy() { void UMLApp::slotEditPaste() { slotStatusMsg(i18n("Inserting clipboard contents...")); - TQMimeSource* data = TQApplication::clipboard()->data(); + TQMimeSource* data = TQApplication::tqclipboard()->data(); UMLClipboard clipboard; setCursor(KCursor::waitCursor()); if(!clipboard.paste(data)) { @@ -895,7 +895,7 @@ void UMLApp::slotStatusMsg(const TQString &text) { statusBar()->clear(); m_statusLabel->setText( text ); - m_statusLabel->repaint(); + m_statusLabel->tqrepaint(); } void UMLApp::slotClassDiagram() { @@ -977,12 +977,12 @@ void UMLApp::enableRedo(bool enable) { /** initialize the QT's global clipboard support for the application */ void UMLApp::initClip() { - QClipboard* clip = TQApplication::clipboard(); + TQClipboard* clip = TQApplication::tqclipboard(); connect(clip, TQT_SIGNAL(dataChanged()), this, TQT_SLOT(slotClipDataChanged())); // Don't poll the X11 clipboard every second. This is a little expensive and resulted - // in very annoying umbrello slowdowns / hangs. Qt will notify us about clipboard - // changes anyway (see dataChanged() signal above), albeit only when a Qt application + // in very annoying umbrello slowdowns / hangs. TQt will notify us about clipboard + // changes anyway (see dataChanged() signal above), albeit only when a TQt application // changes the clipboard. Work is in progress to make this work with other toolkits // as well. (pfeiffer) // m_clipTimer = new TQTimer(this, "timer"); @@ -1007,7 +1007,7 @@ bool UMLApp::canDecode(const TQMimeSource* mimeSource) { } void UMLApp::slotClipDataChanged() { - TQMimeSource * data = TQApplication::clipboard()->data(); + TQMimeSource * data = TQApplication::tqclipboard()->data(); //Pass the MimeSource to the Doc editPaste->setEnabled( data && canDecode(data) ); @@ -1075,7 +1075,7 @@ bool UMLApp::editCutCopy( bool bFromView ) { TQMimeSource * clipdata = 0; if ((clipdata = clipboard.copy(bFromView)) != 0) { - QClipboard* clip = TQApplication::clipboard(); + TQClipboard* clip = TQApplication::tqclipboard(); clip->setData(clipdata);//the global clipboard takes ownership of the clipdata memory connect(clip, TQT_SIGNAL(dataChanged()), this, TQT_SLOT(slotClipDataChanged())); return true; @@ -1122,7 +1122,7 @@ void UMLApp::readOptionState() { m_config -> setGroup( "UI Options" ); optionState.uiState.useFillColor = m_config -> readBoolEntry( "useFillColor", true ); TQColor defaultYellow = TQColor( 255, 255, 192 ); - TQColor red ( Qt::red ); + TQColor red ( TQt::red ); optionState.uiState.fillColor = m_config -> readColorEntry( "fillColor", &defaultYellow ); optionState.uiState.lineColor = m_config -> readColorEntry( "lineColor", &red ); @@ -1484,12 +1484,12 @@ void UMLApp::updateLangSelectMenu(Uml::Programming_Language activeLanguage) { void UMLApp::tipOfTheDay() { - KTipDialog::showTip(this ,TQString::null, true); + KTipDialog::showTip(this ,TQString(), true); } void UMLApp::keyPressEvent(TQKeyEvent *e) { switch(e->key()) { - case Qt::Key_Shift: + case TQt::Key_Shift: //toolsbar->setOldTool(); e->accept(); break; @@ -1511,23 +1511,23 @@ void UMLApp::customEvent(TQCustomEvent* e) { void UMLApp::handleCursorKeyReleaseEvent(TQKeyEvent* e) { // in case we have selected something in the diagram, move it by one pixel // to the direction pointed by the cursor key - if (m_view == NULL || !m_view->getSelectCount() || e->state() != Qt::AltButton) { + if (m_view == NULL || !m_view->getSelectCount() || e->state() != TQt::AltButton) { e->ignore(); return; } int dx = 0; int dy = 0; switch (e->key()) { - case Qt::Key_Left: + case TQt::Key_Left: dx = -1; break; - case Qt::Key_Right: + case TQt::Key_Right: dx = 1; break; - case Qt::Key_Up: + case TQt::Key_Up: dy = -1; break; - case Qt::Key_Down: + case TQt::Key_Down: dy = 1; break; default: @@ -1546,19 +1546,19 @@ void UMLApp::handleCursorKeyReleaseEvent(TQKeyEvent* e) { void UMLApp::keyReleaseEvent(TQKeyEvent *e) { switch(e->key()) { - case Qt::Key_Backspace: + case TQt::Key_Backspace: if (!m_pDocWindow->isTyping()) toolsbar->setOldTool(); e->accept(); break; - case Qt::Key_Escape: + case TQt::Key_Escape: toolsbar->setDefaultTool(); e->accept(); break; - case Qt::Key_Left: - case Qt::Key_Right: - case Qt::Key_Up: - case Qt::Key_Down: + case TQt::Key_Left: + case TQt::Key_Right: + case TQt::Key_Up: + case TQt::Key_Down: handleCursorKeyReleaseEvent(e); break; default: @@ -1616,7 +1616,7 @@ TQPopupMenu* UMLApp::findMenu(TQMenuData* menu, const TQString &name) { for (int i=0; i<menuCount; i++) { int idAt = menu->idAt(i); - TQPopupMenu* popupMenu = menu->findItem(idAt)->popup(); + TQPopupMenu* popupMenu = menu->tqfindItem(idAt)->popup(); if (popupMenu) { TQString menuName = popupMenu->name(); if( menuName == name) { @@ -1640,7 +1640,7 @@ void UMLApp::slotChangeTabLeft() { } UMLViewList views = m_doc->getViewIterator(); UMLView *currView = m_view; - if (views.find(currView) < 0) { + if (views.tqfind(currView) < 0) { kError() << "UMLApp::slotChangeTabLeft(): currView not found in viewlist" << endl; return; } @@ -1657,7 +1657,7 @@ void UMLApp::slotChangeTabRight() { } UMLViewList views = m_doc->getViewIterator(); UMLView *currView = m_view; - if (views.find(currView) < 0) { + if (views.tqfind(currView) < 0) { kError() << "UMLApp::slotChangeTabRight(): currView not found in viewlist" << endl; return; } @@ -1679,10 +1679,10 @@ void UMLApp::slotMoveTabRight() { //m_tabWidget->moveTab( m_tabWidget->currentPageIndex(), m_tabWidget->currentPageIndex() + 1 ); } -void UMLApp::slotAutolayout(){ +void UMLApp::slotAutotqlayout(){ #ifdef HAVE_DOT /* - TQDialog* d = new AutolayoutDlg(getCurrentView()); + TQDialog* d = new AutotqlayoutDlg(getCurrentView()); d->show(); */ #endif |