summaryrefslogtreecommitdiffstats
path: root/src/ktechlab.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ktechlab.cpp')
-rw-r--r--src/ktechlab.cpp252
1 files changed, 126 insertions, 126 deletions
diff --git a/src/ktechlab.cpp b/src/ktechlab.cpp
index cc89ffb..1e10245 100644
--- a/src/ktechlab.cpp
+++ b/src/ktechlab.cpp
@@ -34,10 +34,10 @@
#include "textview.h"
#include "viewcontainer.h"
-#include <qdockarea.h>
-#include <qtimer.h>
-#include <qtoolbutton.h>
-#include <qwhatsthis.h>
+#include <tqdockarea.h>
+#include <tqtimer.h>
+#include <tqtoolbutton.h>
+#include <tqwhatsthis.h>
#include <kaccel.h>
#include <kapplication.h>
@@ -58,7 +58,7 @@
KTechlab::KTechlab()
: KateMDI::MainWindow( 0, "KTechlab" )
{
- QTime ct;
+ TQTime ct;
ct.start();
m_bIsShown = false;
@@ -68,8 +68,8 @@ KTechlab::KTechlab()
m_pFocusedContainer = 0l;
m_pToolBarOverlayLabel = 0l;
- m_pUpdateCaptionsTimer = new QTimer( this );
- connect( m_pUpdateCaptionsTimer, SIGNAL(timeout()), this, SLOT(slotUpdateCaptions()) );
+ m_pUpdateCaptionsTimer = new TQTimer( this );
+ connect( m_pUpdateCaptionsTimer, TQT_SIGNAL(timeout()), TQT_TQOBJECT(this), TQT_SLOT(slotUpdateCaptions()) );
setMinimumSize( 400, 400 );
@@ -105,7 +105,7 @@ void KTechlab::show()
void KTechlab::load( const KURL & url )
{
- if ( url.url().endsWith( ".ktechlab", false ) )
+ if ( url.url().tqendsWith( ".ktechlab", false ) )
{
// This is a ktechlab project; it has to be handled separetly from a
// normal file.
@@ -115,7 +115,7 @@ void KTechlab::load( const KURL & url )
}
- QString target;
+ TQString target;
// the below code is what you should normally do. in this
// example case, we want the url to our own. you probably
// want to use this code instead for your app
@@ -143,7 +143,7 @@ void KTechlab::load( const KURL & url )
}
-QStringList KTechlab::recentFiles()
+TQStringList KTechlab::recentFiles()
{
return m_recentFiles->items();
}
@@ -157,7 +157,7 @@ void KTechlab::setupToolDocks()
# endif
#endif
- QPixmap pm;
+ TQPixmap pm;
KIconLoader * loader = KGlobal::iconLoader();
KateMDI::ToolView * tv = 0l;
@@ -227,10 +227,10 @@ void KTechlab::setupToolDocks()
void KTechlab::addWindow( ViewContainer * vc )
{
- if ( vc && !m_viewContainerList.contains(vc) )
+ if ( vc && !m_viewContainerList.tqcontains(vc) )
{
m_viewContainerList << vc;
- connect( vc, SIGNAL(destroyed(QObject* )), this, SLOT(slotViewContainerDestroyed(QObject* )) );
+ connect( vc, TQT_SIGNAL(destroyed(TQObject* )), TQT_TQOBJECT(this), TQT_SLOT(slotViewContainerDestroyed(TQObject* )) );
}
m_viewContainerList.remove((ViewContainer*)0);
@@ -255,7 +255,7 @@ void KTechlab::overlayToolBarScreenshot()
{
if ( !m_pToolBarOverlayLabel )
{
- m_pToolBarOverlayLabel = new QLabel( 0, 0, WStyle_StaysOnTop | WStyle_Customize | WStyle_NoBorder | WNoAutoErase | WType_Popup );
+ m_pToolBarOverlayLabel = new TQLabel( 0, 0, WStyle_StaysOnTop | WStyle_Customize | WStyle_NoBorder | WNoAutoErase | WType_Popup );
m_pToolBarOverlayLabel->hide();
m_pToolBarOverlayLabel->setBackgroundMode( NoBackground );
}
@@ -275,39 +275,39 @@ void KTechlab::overlayToolBarScreenshot()
return;
}
- QPtrListIterator<KToolBar> toolBarIterator();
+ TQPtrListIterator<KToolBar> toolBarIterator();
-// QWidget * toolsWidget = toolBar( "toolsToolBar" );
-// QWidget * debugWidget = toolBar( "debugTB" );
+// TQWidget * toolsWidget = toolBar( "toolsToolBar" );
+// TQWidget * debugWidget = toolBar( "debugTB" );
- KToolBar * toolsWidget = static_cast<KToolBar*>(child( "toolsToolBar", "KToolBar" ));
- KToolBar * debugWidget = static_cast<KToolBar*>(child( "debugTB", "KToolBar" ));
+ KToolBar * toolsWidget = static_cast<KToolBar*>(TQT_TQWIDGET(child( "toolsToolBar", "KToolBar" )));
+ KToolBar * debugWidget = static_cast<KToolBar*>(TQT_TQWIDGET(child( "debugTB", "KToolBar" )));
if ( !toolsWidget && !debugWidget )
return;
- QWidget * parent = static_cast<QWidget*>(toolsWidget ? toolsWidget->parent() : debugWidget->parent());
+ TQWidget * tqparent = TQT_TQWIDGET(toolsWidget ? toolsWidget->tqparent() : debugWidget->tqparent());
- QRect grabRect;
+ TQRect grabRect;
// 128 is a sanity check (widget can do strange things when being destroyed)
if ( toolsWidget && toolsWidget->height() <= 128 )
- grabRect |= toolsWidget->geometry();
+ grabRect |= toolsWidget->tqgeometry();
if ( debugWidget && debugWidget->height() <= 128 )
- grabRect |= debugWidget->geometry();
+ grabRect |= debugWidget->tqgeometry();
if ( !grabRect.isValid() )
return;
- QPixmap shot = QPixmap::grabWidget( parent, grabRect.x(), grabRect.y(), grabRect.width(), grabRect.height() );
+ TQPixmap shot = TQPixmap::grabWidget( tqparent, grabRect.x(), grabRect.y(), grabRect.width(), grabRect.height() );
- m_pToolBarOverlayLabel->move( parent->mapToGlobal( grabRect.topLeft() ) );
+ m_pToolBarOverlayLabel->move( tqparent->mapToGlobal( grabRect.topLeft() ) );
m_pToolBarOverlayLabel->setFixedSize( grabRect.size() );
m_pToolBarOverlayLabel->setPixmap( shot );
m_pToolBarOverlayLabel->show();
- QTimer::singleShot( 100, this, SLOT( hideToolBarOverlay() ) );
+ TQTimer::singleShot( 100, TQT_TQOBJECT(this), TQT_SLOT( hideToolBarOverlay() ) );
}
@@ -316,7 +316,7 @@ void KTechlab::hideToolBarOverlay()
if ( !m_pToolBarOverlayLabel )
return;
-// QWidget * hiddenWidget = toolBar( "toolsToolBar" );
+// TQWidget * hiddenWidget = toolBar( "toolsToolBar" );
// if ( !hiddenWidget )
// return;
@@ -330,19 +330,19 @@ void KTechlab::hideToolBarOverlay()
void KTechlab::addNoRemoveGUIClient( KXMLGUIClient * client )
{
- if ( client && !m_noRemoveGUIClients.contains( client ) )
+ if ( client && !m_noRemoveGUIClients.tqcontains( client ) )
m_noRemoveGUIClients << client;
}
void KTechlab::removeGUIClients()
{
- QValueList<KXMLGUIClient*> clientsToRemove;
+ TQValueList<KXMLGUIClient*> clientsToRemove;
- QPtrList<KXMLGUIClient> clients = factory()->clients();
+ TQPtrList<KXMLGUIClient> clients = factory()->clients();
for ( KXMLGUIClient * client = clients.first(); client; client = clients.next() )
{
- if ( client && client != this && !m_noRemoveGUIClients.contains( client ) )
+ if ( client && client != this && !m_noRemoveGUIClients.tqcontains( client ) )
clientsToRemove << client;
}
@@ -351,8 +351,8 @@ void KTechlab::removeGUIClients()
overlayToolBarScreenshot();
- QValueList<KXMLGUIClient*>::iterator end = clientsToRemove.end();
- for ( QValueList<KXMLGUIClient*>::iterator it = clientsToRemove.begin(); it != end; ++it )
+ TQValueList<KXMLGUIClient*>::iterator end = clientsToRemove.end();
+ for ( TQValueList<KXMLGUIClient*>::iterator it = clientsToRemove.begin(); it != end; ++it )
factory()->removeClient(*it);
}
@@ -360,11 +360,11 @@ void KTechlab::removeGUIClients()
void KTechlab::setupTabWidget()
{
m_pViewContainerTabWidget = new KTabWidget(centralWidget());
- connect( tabWidget(), SIGNAL(currentChanged(QWidget* )), this, SLOT(slotViewContainerActivated(QWidget* )) );
- connect( tabWidget(), SIGNAL(testCanDecode(const QDragMoveEvent*, bool& )), this, SLOT(slotTabDragEvent(const QDragMoveEvent*, bool& )) );
- connect( tabWidget(), SIGNAL(initiateDrag(QWidget* )), this, SLOT(slotTabDragInitiate(QWidget* )) );
- connect( tabWidget(), SIGNAL(receivedDropEvent(QDropEvent* )), this, SLOT(slotTabReceivedDropEvent(QDropEvent* )) );
- connect( tabWidget(), SIGNAL(receivedDropEvent(QWidget*, QDropEvent* )), this, SLOT(slotTabReceivedDropEvent(QWidget*, QDropEvent* )) );
+ connect( tabWidget(), TQT_SIGNAL(currentChanged(TQWidget* )), TQT_TQOBJECT(this), TQT_SLOT(slotViewContainerActivated(TQWidget* )) );
+ connect( tabWidget(), TQT_SIGNAL(testCanDecode(const TQDragMoveEvent*, bool& )), TQT_TQOBJECT(this), TQT_SLOT(slotTabDragEvent(const TQDragMoveEvent*, bool& )) );
+ connect( tabWidget(), TQT_SIGNAL(initiateDrag(TQWidget* )), TQT_TQOBJECT(this), TQT_SLOT(slotTabDragInitiate(TQWidget* )) );
+ connect( tabWidget(), TQT_SIGNAL(receivedDropEvent(TQDropEvent* )), TQT_TQOBJECT(this), TQT_SLOT(slotTabReceivedDropEvent(TQDropEvent* )) );
+ connect( tabWidget(), TQT_SIGNAL(receivedDropEvent(TQWidget*, TQDropEvent* )), TQT_TQOBJECT(this), TQT_SLOT(slotTabReceivedDropEvent(TQWidget*, TQDropEvent* )) );
KConfig *config = kapp->config();
config->setGroup("UI");
@@ -380,16 +380,16 @@ void KTechlab::setupTabWidget()
if (config->readBoolEntry( "ShowCloseTabsButton", true ))
{
- QToolButton *but = new QToolButton(tabWidget());
+ TQToolButton *but = new TQToolButton(tabWidget());
but->setIconSet(SmallIcon("tab_remove"));
but->adjustSize();
but->hide();
- connect( but, SIGNAL(clicked()), this, SLOT(slotViewContainerClose()) );
+ connect( but, TQT_SIGNAL(clicked()), TQT_TQOBJECT(this), TQT_SLOT(slotViewContainerClose()) );
tabWidget()->setCornerWidget(but, TopRight);
}
// tabWidget()->setTabReorderingEnabled(true);
-// connect(tabWidget(), SIGNAL(movedTab(int, int)), this, SLOT(tabMoved(int, int)));
- connect(tabWidget(), SIGNAL(contextMenu(QWidget*,const QPoint &)), this, SLOT(slotTabContext(QWidget*,const QPoint &)));
+// connect(tabWidget(), TQT_SIGNAL(movedTab(int, int)), TQT_TQOBJECT(this), TQT_SLOT(tabMoved(int, int)));
+ connect(tabWidget(), TQT_SIGNAL(contextMenu(TQWidget*,const TQPoint &)), TQT_TQOBJECT(this), TQT_SLOT(slotTabContext(TQWidget*,const TQPoint &)));
//END Tab bar stuff
}
@@ -400,7 +400,7 @@ void KTechlab::slotUpdateTabWidget()
bool noWindows = m_viewContainerList.isEmpty();
- if ( QWidget * button = tabWidget()->cornerWidget(TopRight) )
+ if ( TQWidget * button = tabWidget()->cornerWidget(TopRight) )
button->setHidden( noWindows );
if ( noWindows )
@@ -412,67 +412,67 @@ void KTechlab::setupActions()
{
KActionCollection *ac = actionCollection();
- KStdAction::openNew( this, SLOT(slotFileNew()), ac );
- KStdAction::open( this, SLOT(slotFileOpen()), ac );
- KStdAction::save( this, SLOT(slotFileSave()), ac );
- KStdAction::saveAs( this, SLOT(slotFileSaveAs()), ac );
- KStdAction::close( this, SLOT(slotViewClose()), ac );
- KStdAction::print( this, SLOT(slotFilePrint()), ac );
- KStdAction::quit( this, SLOT(slotFileQuit()), ac );
- KStdAction::undo( this, SLOT(slotEditUndo()), ac );
- KStdAction::redo( this, SLOT(slotEditRedo()), ac );
- KStdAction::cut( this, SLOT(slotEditCut()), ac );
- KStdAction::copy( this, SLOT(slotEditCopy()), ac );
- KStdAction::paste( this, SLOT(slotEditPaste()), ac );
- KStdAction::keyBindings( this, SLOT(slotOptionsConfigureKeys()), ac );
- KStdAction::configureToolbars( this, SLOT(slotOptionsConfigureToolbars()), ac );
- KStdAction::preferences( this, SLOT(slotOptionsPreferences()), ac );
+ KStdAction::openNew( TQT_TQOBJECT(this), TQT_SLOT(slotFileNew()), ac );
+ KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT(slotFileOpen()), ac );
+ KStdAction::save( TQT_TQOBJECT(this), TQT_SLOT(slotFileSave()), ac );
+ KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT(slotFileSaveAs()), ac );
+ KStdAction::close( TQT_TQOBJECT(this), TQT_SLOT(slotViewClose()), ac );
+ KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT(slotFilePrint()), ac );
+ KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT(slotFileQuit()), ac );
+ KStdAction::undo( TQT_TQOBJECT(this), TQT_SLOT(slotEditUndo()), ac );
+ KStdAction::redo( TQT_TQOBJECT(this), TQT_SLOT(slotEditRedo()), ac );
+ KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT(slotEditCut()), ac );
+ KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(slotEditCopy()), ac );
+ KStdAction::paste( TQT_TQOBJECT(this), TQT_SLOT(slotEditPaste()), ac );
+ KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT(slotOptionsConfigureKeys()), ac );
+ KStdAction::configureToolbars( TQT_TQOBJECT(this), TQT_SLOT(slotOptionsConfigureToolbars()), ac );
+ KStdAction::preferences( TQT_TQOBJECT(this), TQT_SLOT(slotOptionsPreferences()), ac );
//BEGIN New file popup
- KToolBarPopupAction *p = new KToolBarPopupAction( i18n("&New"), "filenew", KStdAccel::shortcut(KStdAccel::New), this, SLOT(slotFileNew()), ac, "newfile_popup" );
+ KToolBarPopupAction *p = new KToolBarPopupAction( i18n("&New"), "filenew", KStdAccel::shortcut(KStdAccel::New), TQT_TQOBJECT(this), TQT_SLOT(slotFileNew()), ac, "newfile_popup" );
p->popupMenu()->insertTitle( i18n("New File") );
- (new KAction( i18n("Assembly"), "source", 0, this, SLOT(slotFileNewAssembly()), ac, "newfile_asm" ))->plug( p->popupMenu() );
- (new KAction( i18n("C source"), "source_c", 0, this, SLOT(slotFileNewC()), ac, "newfile_c" ))->plug( p->popupMenu() );
- (new KAction( i18n("Circuit"), "ktechlab_circuit", 0, this, SLOT(slotFileNewCircuit()), ac, "newfile_circuit" ))->plug( p->popupMenu() );
- (new KAction( i18n("FlowCode"), "ktechlab_flowcode", 0, this, SLOT(slotFileNewFlowCode()), ac, "newfile_flowcode" ))->plug( p->popupMenu() );
+ (new KAction( i18n("Assembly"), "source", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFileNewAssembly()), ac, "newfile_asm" ))->plug( p->popupMenu() );
+ (new KAction( i18n("C source"), "source_c", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFileNewC()), ac, "newfile_c" ))->plug( p->popupMenu() );
+ (new KAction( i18n("Circuit"), "ktechlab_circuit", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFileNewCircuit()), ac, "newfile_circuit" ))->plug( p->popupMenu() );
+ (new KAction( i18n("FlowCode"), "ktechlab_flowcode", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFileNewFlowCode()), ac, "newfile_flowcode" ))->plug( p->popupMenu() );
#ifdef MECHANICS
- (new KAction( i18n("Mechanics"), "ktechlab_mechanics", 0, this, SLOT(slotFileNewMechanics()), ac, "newfile_mechanics" ))->plug( p->popupMenu() );
+ (new KAction( i18n("Mechanics"), "ktechlab_mechanics", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFileNewMechanics()), ac, "newfile_mechanics" ))->plug( p->popupMenu() );
#endif
- (new KAction( "Microbe", "ktechlab_microbe", 0, this, SLOT(slotFileNewMicrobe()), ac, "newfile_microbe" ))->plug( p->popupMenu() );
+ (new KAction( "Microbe", "ktechlab_microbe", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFileNewMicrobe()), ac, "newfile_microbe" ))->plug( p->popupMenu() );
//END New File popup
-// m_recentFiles = KStdAction::openRecent( this, SLOT(load(const KURL&)), ac );
- m_recentFiles = new RecentFilesAction( "Recent Files", i18n("Open Recent"), this, SLOT(load(const KURL &)), ac, "file_open_recent" );
- m_statusbarAction = KStdAction::showStatusbar( this, SLOT(slotOptionsShowStatusbar()), ac );
+// m_recentFiles = KStdAction::openRecent( TQT_TQOBJECT(this), TQT_SLOT(load(const KURL&)), ac );
+ m_recentFiles = new RecentFilesAction( "Recent Files", i18n("Open Recent"), TQT_TQOBJECT(this), TQT_SLOT(load(const KURL &)), ac, "file_open_recent" );
+ m_statusbarAction = KStdAction::showStatusbar( TQT_TQOBJECT(this), TQT_SLOT(slotOptionsShowStatusbar()), ac );
//BEGIN Project Actions
ProjectManager *pm = ProjectManager::self(this);
- new KAction( i18n("New Project.."), "window_new", 0, pm, SLOT(slotNewProject()), ac, "project_new" );
- new KAction( i18n("Open Project..."), "project_open", 0, pm, SLOT(slotOpenProject()), ac, "project_open" );
-// m_recentProjects = new KRecentFilesAction( i18n("Open &Recent Project..."), 0, ProjectManager::self(), SLOT(slotOpenProject(const KURL&)), ac, "project_open_recent" );
- m_recentProjects = new RecentFilesAction( "Recent Projects", i18n("Open &Recent Project..."), ProjectManager::self(), SLOT(slotOpenProject(const KURL&)), ac, "project_open_recent" );
- new KAction( i18n("Export to Makefile..."), "fileexport", 0, pm, SLOT(slotExportToMakefile()), ac, "project_export_makefile" );
- new KAction( i18n("Create Subproject..."), 0, 0, pm, SLOT(slotCreateSubproject()), ac, "project_create_subproject" );
- new KAction( i18n("Add Existing File..."), "fileopen", 0, pm, SLOT(slotAddFile()), ac, "project_add_existing_file" );
- new KAction( i18n("Add Current File..."), "fileimport", 0, pm, SLOT(slotAddCurrentFile()), ac, "project_add_current_file" );
-// new KAction( i18n("Project Options"), "configure", 0, pm, SLOT(slotProjectOptions()), ac, "project_options" );
- new KAction( i18n("Close Project"), "fileclose", 0, pm, SLOT(slotCloseProject()), ac, "project_close" );
- new KAction( i18n("Remove from Project"), "editdelete", 0, pm, SLOT(slotRemoveSelected()), ac, "project_remove_selected" );
- new KAction( i18n("Insert Existing File..."), "fileopen", 0, pm, SLOT(slotSubprojectAddExistingFile()), ac, "subproject_add_existing_file" );
- new KAction( i18n("Insert Current File..."), "fileimport", 0, pm, SLOT(slotSubprojectAddCurrentFile()),ac, "subproject_add_current_file" );
- new KAction( i18n("Linker Options..."), "configure", 0, pm, SLOT(slotSubprojectLinkerOptions()), ac, "project_item_linker_options" );
- new KAction( i18n("Build..."), "launch", 0, pm, SLOT(slotItemBuild()), ac, "project_item_build" );
- new KAction( i18n("Upload..."), "convert_to_pic", 0, pm, SLOT(slotItemUpload()), ac, "project_item_upload" );
- new KAction( i18n("Processing Options..."), "configure", 0, pm, SLOT(slotItemProcessingOptions()), ac, "project_item_processing_options" );
+ new KAction( i18n("New Project.."), "window_new", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotNewProject()), ac, "project_new" );
+ new KAction( i18n("Open Project..."), "project_open", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotOpenProject()), ac, "project_open" );
+// m_recentProjects = new KRecentFilesAction( i18n("Open &Recent Project..."), 0, ProjectManager::self(), TQT_SLOT(slotOpenProject(const KURL&)), ac, "project_open_recent" );
+ m_recentProjects = new RecentFilesAction( "Recent Projects", i18n("Open &Recent Project..."), TQT_TQOBJECT(ProjectManager::self()), TQT_SLOT(slotOpenProject(const KURL&)), ac, "project_open_recent" );
+ new KAction( i18n("Export to Makefile..."), "fileexport", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotExportToMakefile()), ac, "project_export_makefile" );
+ new KAction( i18n("Create Subproject..."), 0, 0, TQT_TQOBJECT(pm), TQT_SLOT(slotCreateSubproject()), ac, "project_create_subproject" );
+ new KAction( i18n("Add Existing File..."), "fileopen", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotAddFile()), ac, "project_add_existing_file" );
+ new KAction( i18n("Add Current File..."), "fileimport", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotAddCurrentFile()), ac, "project_add_current_file" );
+// new KAction( i18n("Project Options"), "configure", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotProjectOptions()), ac, "project_options" );
+ new KAction( i18n("Close Project"), "fileclose", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotCloseProject()), ac, "project_close" );
+ new KAction( i18n("Remove from Project"), "editdelete", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotRemoveSelected()), ac, "project_remove_selected" );
+ new KAction( i18n("Insert Existing File..."), "fileopen", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotSubprojectAddExistingFile()), ac, "subproject_add_existing_file" );
+ new KAction( i18n("Insert Current File..."), "fileimport", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotSubprojectAddCurrentFile()),ac, "subproject_add_current_file" );
+ new KAction( i18n("Linker Options..."), "configure", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotSubprojectLinkerOptions()), ac, "project_item_linker_options" );
+ new KAction( i18n("Build..."), "launch", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotItemBuild()), ac, "project_item_build" );
+ new KAction( i18n("Upload..."), "convert_to_pic", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotItemUpload()), ac, "project_item_upload" );
+ new KAction( i18n("Processing Options..."), "configure", 0, TQT_TQOBJECT(pm), TQT_SLOT(slotItemProcessingOptions()), ac, "project_item_processing_options" );
//END Project Actions
- new KAction( i18n("Split View Left/Right"), "view_right", Qt::CTRL|Qt::SHIFT|Qt::Key_L, this, SLOT(slotViewSplitLeftRight()), ac, "view_split_leftright" );
- new KAction( i18n("Split View Top/Bottom"), "view_bottom", Qt::CTRL|Qt::SHIFT|Qt::Key_T, this, SLOT(slotViewSplitTopBottom()), ac, "view_split_topbottom" );
+ new KAction( i18n("Split View Left/Right"), "view_right", TQt::CTRL|TQt::SHIFT|TQt::Key_L, TQT_TQOBJECT(this), TQT_SLOT(slotViewSplitLeftRight()), ac, "view_split_leftright" );
+ new KAction( i18n("Split View Top/Bottom"), "view_bottom", TQt::CTRL|TQt::SHIFT|TQt::Key_T, TQT_TQOBJECT(this), TQT_SLOT(slotViewSplitTopBottom()), ac, "view_split_topbottom" );
- KToggleAction * ta = new KToggleAction( i18n("Run Simulation"), "player_play", Qt::Key_F10, 0, 0, ac, "simulation_run" );
+ KToggleAction * ta = new KToggleAction( i18n("Run Simulation"), "player_play", TQt::Key_F10, 0, 0, ac, "simulation_run" );
ta->setChecked(true);
- connect( ta, SIGNAL(toggled(bool )), Simulator::self(), SLOT(slotSetSimulating(bool )) );
+ connect( ta, TQT_SIGNAL(toggled(bool )), Simulator::self(), TQT_SLOT(slotSetSimulating(bool )) );
#if defined(KDE_MAKE_VERSION)
# if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
ta->setCheckedState( KGuiItem( i18n("Pause Simulation"), "player_pause", 0 ) );
@@ -486,7 +486,7 @@ void KTechlab::setupActions()
}
-void KTechlab::slotViewContainerActivated( QWidget * viewContainer )
+void KTechlab::slotViewContainerActivated( TQWidget * viewContainer )
{
if (m_pFocusedContainer)
m_pFocusedContainer->setUnfocused();
@@ -499,15 +499,15 @@ void KTechlab::slotViewContainerActivated( QWidget * viewContainer )
}
-void KTechlab::slotViewContainerDestroyed( QObject * object )
+void KTechlab::slotViewContainerDestroyed( TQObject * object )
{
- m_viewContainerList.remove( static_cast<ViewContainer*>(object) );
+ m_viewContainerList.remove( static_cast<ViewContainer*>(TQT_TQWIDGET(object)) );
m_viewContainerList.remove( (ViewContainer*)0 );
slotUpdateTabWidget();
}
-void KTechlab::slotTabDragEvent( const QDragMoveEvent *e, bool &accept )
+void KTechlab::slotTabDragEvent( const TQDragMoveEvent *e, bool &accept )
{
// Hmm...this function doesn't actually seem to get called. Instead,
// KTabBar just seems to go straight to slotTabDragInitiate.
@@ -516,17 +516,17 @@ void KTechlab::slotTabDragEvent( const QDragMoveEvent *e, bool &accept )
}
-void KTechlab::slotTabDragInitiate( QWidget *widget )
+void KTechlab::slotTabDragInitiate( TQWidget *widget )
{
ViewContainer *viewContainer = dynamic_cast<ViewContainer*>(widget);
if (!viewContainer)
return;
- QDragObject *dragObject = new ViewContainerDrag(viewContainer);
+ TQDragObject *dragObject = new ViewContainerDrag(viewContainer);
dragObject->drag();
}
-void KTechlab::slotTabReceivedDropEvent( QDropEvent *e )
+void KTechlab::slotTabReceivedDropEvent( TQDropEvent *e )
{
if (!e)
return;
@@ -541,7 +541,7 @@ void KTechlab::slotTabReceivedDropEvent( QDropEvent *e )
}
-void KTechlab::slotTabReceivedDropEvent( QWidget *widget, QDropEvent *e )
+void KTechlab::slotTabReceivedDropEvent( TQWidget *widget, TQDropEvent *e )
{
if (!e)
return;
@@ -560,9 +560,9 @@ void KTechlab::slotTabReceivedDropEvent( QWidget *widget, QDropEvent *e )
dropMenu.insertSeparator();
dropMenu.insertItem( KGlobal::iconLoader()->loadIcon( "stop", KIcon::Small ), i18n("C&ancel"), 2 );
- connect( &dropMenu, SIGNAL(activated(int)), this, SLOT(slotDragContextActivated(int)) );
+ connect( &dropMenu, TQT_SIGNAL(activated(int)), TQT_TQOBJECT(this), TQT_SLOT(slotDragContextActivated(int)) );
// dropMenu.exec(e->pos() + widget->pos() );
- dropMenu.exec( QCursor::pos() );
+ dropMenu.exec( TQCursor::pos() );
}
@@ -587,7 +587,7 @@ void KTechlab::slotDragContextActivated( int id )
}
-KAction * KTechlab::action( const QString & name ) const
+KAction * KTechlab::action( const TQString & name ) const
{
KAction * action = actionCollection()->action(name);
if ( !action )
@@ -618,9 +618,9 @@ void KTechlab::saveProperties( KConfig *conf )
//BEGIN Open Views State
// Remvoe old entries describing the save state - we don't want a horrible mish-mash of saved states
- const QStringList groupList = conf->groupList();
- const QStringList::const_iterator groupListEnd = groupList.end();
- for ( QStringList::const_iterator it = groupList.begin(); it != groupListEnd; ++it )
+ const TQStringList groupList = conf->groupList();
+ const TQStringList::const_iterator groupListEnd = groupList.end();
+ for ( TQStringList::const_iterator it = groupList.begin(); it != groupListEnd; ++it )
{
if ( (*it).startsWith("ViewContainer") )
conf->deleteGroup(*it);
@@ -635,7 +635,7 @@ void KTechlab::saveProperties( KConfig *conf )
// To make sure the ViewContainers are restored in the right order, we must create them in alphabetical order,
// as KConfig stores them as such...
- const QString id = QString::number(viewContainerId++).rightJustify( 4, '0' );
+ const TQString id = TQString::number(viewContainerId++).rightJustify( 4, '0' );
conf->setGroup( "ViewContainer " + id );
(*it)->saveState(conf);
@@ -645,10 +645,10 @@ void KTechlab::saveProperties( KConfig *conf )
saveSession( conf, "KateMDI" );
// Piss off KMainWindow
conf->setGroup("KateMDI");
- int scnum = QApplication::desktop()->screenNumber(parentWidget());
- QRect desk = QApplication::desktop()->screenGeometry(scnum);
- conf->deleteEntry( QString::fromLatin1("Width %1").arg(desk.width()) );
- conf->deleteEntry( QString::fromLatin1("Height %1").arg(desk.height()) );
+ int scnum = TQApplication::desktop()->screenNumber(tqparentWidget());
+ TQRect desk = TQApplication::desktop()->screenGeometry(scnum);
+ conf->deleteEntry( TQString::tqfromLatin1("Width %1").tqarg(desk.width()) );
+ conf->deleteEntry( TQString::tqfromLatin1("Height %1").tqarg(desk.height()) );
conf->sync();
}
@@ -666,11 +666,11 @@ void KTechlab::readProperties( KConfig *conf )
{
// If we have a lot of views open from last time, then opening them will take a long time.
// So we want to enter the qt event loop to finish drawing the window et al before adding the views.
- qApp->processEvents();
+ tqApp->processEvents();
- const QStringList groupList = conf->groupList();
- const QStringList::const_iterator groupListEnd = groupList.end();
- for ( QStringList::const_iterator it = groupList.begin(); it != groupListEnd; ++it )
+ const TQStringList groupList = conf->groupList();
+ const TQStringList::const_iterator groupListEnd = groupList.end();
+ for ( TQStringList::const_iterator it = groupList.begin(); it != groupListEnd; ++it )
{
if ( (*it).startsWith("ViewContainer") )
{
@@ -686,7 +686,7 @@ void KTechlab::readProperties( KConfig *conf )
//END Restore Open Views
conf->setGroup("Project");
- if ( conf->readPathEntry("Open") != QString::null )
+ if ( conf->readPathEntry("Open") != TQString() )
ProjectManager::self()->slotOpenProject( KURL( conf->readPathEntry("Open") ) );
#ifndef NO_GPSIM
@@ -702,17 +702,17 @@ void KTechlab::readProperties( KConfig *conf )
}
-void KTechlab::dragEnterEvent(QDragEnterEvent *event)
+void KTechlab::dragEnterEvent(TQDragEnterEvent *event)
{
// accept uri drops only
event->accept(KURLDrag::canDecode(event));
}
-void KTechlab::dropEvent(QDropEvent *event)
+void KTechlab::dropEvent(TQDropEvent *event)
{
// this is a very simplistic implementation of a drop event. we
- // will only accept a dropped URL. the Qt dnd code can do *much*
+ // will only accept a dropped URL. the TQt dnd code can do *much*
// much more, so please read the docs there
KURL::List urls;
@@ -773,7 +773,7 @@ void KTechlab::slotOptionsPreferences()
// User edited the configuration - update your local copies of the
// configuration data
- connect( dialog, SIGNAL(settingsChanged()), this, SLOT(slotUpdateConfiguration()) );
+ connect( dialog, TQT_SIGNAL(settingsChanged()), TQT_TQOBJECT(this), TQT_SLOT(slotUpdateConfiguration()) );
dialog->show();
}
@@ -784,9 +784,9 @@ void KTechlab::slotUpdateConfiguration()
}
-void KTechlab::slotChangeStatusbar( const QString & text )
+void KTechlab::slotChangeStatusbar( const TQString & text )
{
- // Avoid flicker by repeatedly displaying the same message, as QStatusBar does not check for this
+ // Avoid flicker by repeatedly displaying the same message, as TQStatusBar does not check for this
if ( m_lastStatusBarMessage == text )
return;
@@ -795,7 +795,7 @@ void KTechlab::slotChangeStatusbar( const QString & text )
}
-void KTechlab::slotTabContext( QWidget* widget,const QPoint & pos )
+void KTechlab::slotTabContext( TQWidget* widget,const TQPoint & pos )
{
// Shamelessly stolen from KDevelop...
@@ -831,7 +831,7 @@ void KTechlab::slotTabContext( QWidget* widget,const QPoint & pos )
}
}
- connect( tabMenu, SIGNAL( activated(int) ), this, SLOT(slotTabContextActivated(int)) );
+ connect( tabMenu, TQT_SIGNAL( activated(int) ), TQT_TQOBJECT(this), TQT_SLOT(slotTabContextActivated(int)) );
tabMenu->exec(pos);
delete tabMenu;
@@ -848,7 +848,7 @@ void KTechlab::slotTabContextActivated( int id )
View *view = m_pContextMenuContainer->activeView();
if (!view)
return;
- QGuardedPtr<Document> document = view->document();
+ TQGuardedPtr<Document> document = view->document();
switch(id)
{
@@ -931,7 +931,7 @@ void KTechlab::slotFileNew()
bool addToProject = newFileDlg->addToProject();
bool accepted = newFileDlg->accepted();
int finalType = newFileDlg->fileType();
- QString microID = newFileDlg->microID();
+ TQString microID = newFileDlg->microID();
int codeType = newFileDlg->codeType();
delete newFileDlg;
@@ -991,7 +991,7 @@ void KTechlab::addRecentFile( const KURL &url )
KURL::List KTechlab::getFileURLs()
{
return KFileDialog::getOpenURLs(
- QString::null,
+ TQString(),
"*|All Files\n"
"*.asm *.src *.inc|Assembly Code (*.asm, *.src, *.inc)\n"
"*.hex|Intel Hex (*.hex)\n"
@@ -1015,7 +1015,7 @@ void KTechlab::slotDocModifiedChanged()
if ( !vc || !vc->activeView() || !vc->activeView()->document() )
continue;
- QString iconName;
+ TQString iconName;
if ( vc->activeView()->document()->isModified() )
iconName = "filesave";
@@ -1062,7 +1062,7 @@ void KTechlab::slotUpdateCaptions()
{
//BEGIN Set KTechlab caption
Document *document = DocManager::self()->getFocusedDocument();
- QString newCaption;
+ TQString newCaption;
if ( document )
{
KURL url = document->url();