CDlgEditMapLevel::CDlgEditMapLevel(QTreeWidgetItem * item, const QString& path, QWidget * parent) : QDialog(parent) , item(item) , mapPath(path) { setupUi(this); spinZoom->setValue(item->data(0,CCreateMapQMAP::eZoom).toInt()); listFiles->addItems(item->text(CCreateMapQMAP::eFiles).split("; ",QString::SkipEmptyParts)); toolFiles->setIcon(QPixmap(":/icons/iconFileLoad16x16.png")); connect(toolFiles, SIGNAL(clicked()), this, SLOT(slotSelectFiles())); toolAdd->setIcon(QPixmap(":/icons/iconFileAdd16x16.png")); connect(toolAdd, SIGNAL(clicked()), this, SLOT(slotAdd())); toolDel->setIcon(QPixmap(":/icons/iconFileDel16x16.png")); connect(toolDel, SIGNAL(clicked()), this, SLOT(slotDel())); toolUp->setIcon(QPixmap(":/icons/iconUpload16x16.png")); connect(toolUp, SIGNAL(clicked()), this, SLOT(slotUp())); toolDown->setIcon(QPixmap(":/icons/iconDownload16x16.png")); connect(toolDown, SIGNAL(clicked()), this, SLOT(slotDown())); connect(listFiles, SIGNAL(itemSelectionChanged()), this, SLOT(slotListChanged())); }
void KHelpMain::createToolbar() { QPixmap pixmap; QString pmpath; KToolBar *tb = new KToolBar( this ); pixmap = kapp->getIconLoader()->loadIcon( "back.xpm" ); tb->insertButton(pixmap, 0, SIGNAL( clicked() ), helpwin, SLOT( slotBack() ), FALSE, klocale->translate("Previous Document")); pixmap = kapp->getIconLoader()->loadIcon( "forward.xpm" ); tb->insertButton(pixmap, 1, SIGNAL( clicked() ), helpwin, SLOT( slotForward() ), FALSE, klocale->translate("Next Document")); tb->insertSeparator(); pixmap = kapp->getIconLoader()->loadIcon( "prev.xpm" ); tb->insertButton(pixmap, 2, SIGNAL( clicked() ), helpwin, SLOT( slotPrev() ), FALSE, klocale->translate("Previous Node")); pixmap = kapp->getIconLoader()->loadIcon( "next.xpm" ); tb->insertButton(pixmap, 3, SIGNAL( clicked() ), helpwin, SLOT( slotNext() ), FALSE, klocale->translate("Next Node")); pixmap = kapp->getIconLoader()->loadIcon( "up.xpm" ); tb->insertButton(pixmap, 4, SIGNAL( clicked() ), helpwin, SLOT( slotUp() ), FALSE,klocale->translate( "Up one Node")); pixmap = kapp->getIconLoader()->loadIcon( "top.xpm" ); tb->insertButton(pixmap, 5, SIGNAL( clicked() ), helpwin, SLOT( slotTop() ), FALSE, klocale->translate("Top Node")); tb->insertSeparator(); pixmap = kapp->getIconLoader()->loadIcon( "contents.xpm" ); tb->insertButton(pixmap, 6, SIGNAL( clicked() ), helpwin, SLOT( slotDir() ), FALSE, klocale->translate("Help Contents")); pixmap = kapp->getIconLoader()->loadIcon( "reload.xpm" ); tb->insertButton(pixmap, 7, SIGNAL( clicked() ), helpwin, SLOT( slotReload() ), TRUE, klocale->translate( "Reload current document" ) ); pixmap = kapp->getIconLoader()->loadIcon( "stop.xpm" ); tb->insertButton(pixmap, 8, SIGNAL( clicked() ), helpwin, SLOT( slotStopProcessing() ), FALSE, klocale->translate("Stop")); tb->setBarPos( KToolBar::Top ); toolbar = tb; }
ConfFilters::ConfFilters(TQWidget *parent, const char *name) : TQWidget(parent, name) { m_filters = new TDEListView(this); m_filters->addColumn(i18n("Mime Type")); m_filters->addColumn(i18n("Command")); m_filters->setFrameStyle(TQFrame::WinPanel|TQFrame::Sunken); m_filters->setLineWidth(1); m_filters->setSorting(-1); m_filters->header()->setStretchEnabled(true, 1); connect(m_filters, TQT_SIGNAL(doubleClicked(TQListViewItem*)), TQT_SLOT(slotChange())); m_add = new TQPushButton(this); m_add->setPixmap(BarIcon("document-new")); m_remove = new TQPushButton(this); m_remove->setIconSet(BarIconSet("remove")); m_change = new TQPushButton(this); m_change->setIconSet(BarIconSet("filter")); m_up = new TQPushButton(this); m_up->setIconSet(BarIconSet("go-up")); m_down = new TQPushButton(this); m_down->setIconSet(BarIconSet("go-down")); connect(m_add, TQT_SIGNAL(clicked()), TQT_SLOT(slotAdd())); connect(m_change, TQT_SIGNAL(clicked()), TQT_SLOT(slotChange())); connect(m_remove, TQT_SIGNAL(clicked()), TQT_SLOT(slotRemove())); connect(m_up, TQT_SIGNAL(clicked()), TQT_SLOT(slotUp())); connect(m_down, TQT_SIGNAL(clicked()), TQT_SLOT(slotDown())); TQToolTip::add(m_add, i18n("Add filter")); TQToolTip::add(m_change, i18n("Modify filter")); TQToolTip::add(m_remove, i18n("Remove filter")); TQToolTip::add(m_up, i18n("Move filter up")); TQToolTip::add(m_down, i18n("Move filter down")); TQHBoxLayout *l0 = new TQHBoxLayout(this, 10, 10); TQVBoxLayout *l1 = new TQVBoxLayout(0, 0, 0); l0->addWidget(m_filters, 1); l0->addLayout(l1, 0); l1->addWidget(m_add); l1->addWidget(m_change); l1->addWidget(m_remove); l1->addSpacing(10); l1->addWidget(m_up); l1->addWidget(m_down); l1->addStretch(1); updateButton(); connect(m_filters, TQT_SIGNAL(selectionChanged ()),TQT_SLOT(updateButton())); }
CCreateMapFineTune::CCreateMapFineTune(QWidget * parent) : QWidget(parent) { setupUi(this); toolUp->setIcon(QIcon(":/icons/iconUpload16x16.png")); toolDown->setIcon(QIcon(":/icons/iconDownload16x16.png")); toolLeft->setIcon(QIcon(":/icons/iconLeft16x16.png")); toolRight->setIcon(QIcon(":/icons/iconRight16x16.png")); connect(pushOpenFile, SIGNAL(clicked()), this, SLOT(slotOpenFile())); connect(toolUp, SIGNAL(clicked()), this, SLOT(slotUp())); connect(toolDown, SIGNAL(clicked()), this, SLOT(slotDown())); connect(toolLeft, SIGNAL(clicked()), this, SLOT(slotLeft())); connect(toolRight, SIGNAL(clicked()), this, SLOT(slotRight())); connect(pushSave, SIGNAL(clicked()), this, SLOT(slotSave())); progressBar->hide(); }
void StandGrapher::createGui() { //-------------------------------------------------- // Universal button creator for the navigation bars //-------------------------------------------------- class ButtonCreator { public: static QPushButton * create(QWidget * parent, const QString & objName, const QIcon & icon, const QKeySequence & key, QString toolTip, QWidget * target, const char * slot) { QPushButton * button = new QPushButton(parent); button->setObjectName(objName); button->setFocusPolicy(Qt::NoFocus); connect(button, SIGNAL(pressed()), target, slot); button->setIconSize(QSize(32, 32)); button->setIcon(QIcon(icon)); if (!key.isEmpty()) toolTip += " " + tr("(Shortcut: <b>%1</b>)").arg(key.toString()); button->setToolTip(toolTip); QShortcut * shortcut = new QShortcut(key, target); connect(shortcut, SIGNAL(activated()), target, slot); return button; } }; QList<QPushButton *> buttons; //------------------------------------------- // Horizontal tool box //------------------------------------------- hToolBox = new QFrame(this); hToolBox->setFrameStyle(QFrame::StyledPanel | QFrame::Plain); hToolBox->setAutoFillBackground(true); hToolBox->setCursor(Qt::ArrowCursor); hToolBox->installEventFilter(this); // Create buttons buttons << ButtonCreator::create(hToolBox, "Start_button", QIcon(":/start.png"), Qt::Key_Home, tr("Start"), this, SLOT(slotStart())); buttons << ButtonCreator::create(hToolBox, "Prev_button", QIcon(":/previous.png"), Qt::Key_Left, tr("Previous"), this, SLOT(slotPrevious())); buttons << ButtonCreator::create(hToolBox, "HFit_button", QIcon(":/fit.png"), QKeySequence(), tr("Fit horizontally"), this, SLOT(slotFit())); buttons << ButtonCreator::create(hToolBox, "Next_button", QIcon(":/next.png"), Qt::Key_Right, tr("Next"), this, SLOT(slotNext())); buttons << ButtonCreator::create(hToolBox, "Finish_button", QIcon(":/finish.png"), Qt::Key_End, tr("End"), this, SLOT(slotEnd())); buttons << ButtonCreator::create(hToolBox, "HZoomIn_button", QIcon(":/plus.png"), Qt::Key_Plus, tr("Wider"), this, SLOT(slotZoomIn())); buttons << ButtonCreator::create(hToolBox, "HZoomOut_button", QIcon(":/minus.png"), Qt::Key_Minus, tr("Narrower"), this, SLOT(slotZoomOut())); // Layout buttons QHBoxLayout * hLayout = new QHBoxLayout(hToolBox); foreach(QPushButton * button, buttons) hLayout->addWidget(button); hToolBox->setLayout(hLayout); //------------------------------------------- // Vertical tool box //------------------------------------------- vToolBox = new QFrame(this); vToolBox->setFrameStyle(QFrame::StyledPanel | QFrame::Plain); vToolBox->setAutoFillBackground(true); vToolBox->setCursor(Qt::ArrowCursor); vToolBox->installEventFilter(this); buttons.clear(); buttons << ButtonCreator::create(vToolBox, "Up_button", QIcon(":/up.png"), Qt::Key_Up, tr("Up"), this, SLOT(slotUp())); buttons << ButtonCreator::create(vToolBox, "VFit_button", QIcon(":/fit_vert.png"), QKeySequence(), tr("Fit vertically"), this, SLOT(slotVFit())); buttons << ButtonCreator::create(vToolBox, "Down_button", QIcon(":/down.png"), Qt::Key_Down, tr("Down"), this, SLOT(slotDown())); buttons << ButtonCreator::create(vToolBox, "VZoomIn_button", QIcon(":/plus.png"), Qt::SHIFT+Qt::Key_Plus, tr("Wider"), this, SLOT(slotVZoomIn())); buttons << ButtonCreator::create(vToolBox, "VZoomOut_button", QIcon(":/minus.png"), Qt::SHIFT+Qt::Key_Minus, tr("Narrower"), this, SLOT(slotVZoomOut())); // Layout buttons QVBoxLayout * vLayout = new QVBoxLayout(vToolBox); foreach(QPushButton * button, buttons) vLayout->addWidget(button); vToolBox->setLayout(vLayout); //------------------------------------------- // Tool Box //------------------------------------------- toolBox = new QFrame(this); toolBox->setFrameStyle(QFrame::StyledPanel | QFrame::Plain); toolBox->setAutoFillBackground(true); toolBox->setCursor(Qt::ArrowCursor); toolBox->installEventFilter(this); buttons.clear(); // Filter button filterButton = new QPushButton(toolBox); filterButton->setIcon(QIcon(":/filter.png")); filterButton->setCheckable(true); filterButton->setShortcut(Qt::Key_F); filterButton->setToolTip(tr("Filter window")); connect(filterButton, SIGNAL(released()), this, SLOT(slotFilterWindow())); buttons << filterButton; filterWindow = new ParamsFilterWidget(this); connect(filterWindow, SIGNAL( modelChanged(Stand_trace_model::Ptr) ), this, SLOT( setModel(Stand_trace_model::Ptr) )); connect(filterWindow, SIGNAL(windowClosed()), filterButton, SLOT(toggle())); // Drawing lines option drawLinesButton = new QPushButton(toolBox); drawLinesButton->setIcon(QIcon(":/draw_lines.png")); drawLinesButton->setCheckable(true); drawLinesButton->setChecked(true); drawLinesButton->setShortcut(Qt::Key_L); drawLinesButton->setToolTip(tr("Draw lines")); connect(drawLinesButton, SIGNAL(released()), this, SLOT(slotDrawLineSwither())); buttons << drawLinesButton; // Antialiasing option antialiasingButton = new QPushButton(toolBox); antialiasingButton->setIcon(QIcon(":/antialiasing.png")); antialiasingButton->setCheckable(true); antialiasingButton->setChecked(antialiasing); antialiasingButton->setShortcut(Qt::Key_A); antialiasingButton->setToolTip(tr("Antialiasing")); connect(antialiasingButton, SIGNAL(clicked(bool)), this, SLOT(slotAntialiasingSwither(bool))); buttons << antialiasingButton; // Print button printButton = new QPushButton(toolBox); printButton->setIcon(QIcon(":/printer.png")); printButton->setShortcut(Qt::Key_P); printButton->setToolTip(tr("Print")); connect(printButton, SIGNAL(released()), this, SLOT(slotPrintGraph())); buttons << printButton; // Setup buttons foreach (QPushButton * button, buttons) { button->setIconSize(QSize(16, 16)); button->setFocusPolicy(Qt::NoFocus); button->setToolTip(button->toolTip() + " " + tr("(Shortcut: <b>%1</b>)").arg(button->shortcut().toString())); }
KMConfigFonts::KMConfigFonts(TQWidget *parent, const char *name) : KMConfigPage(parent, name) { setPageName(i18n("Fonts")); setPageHeader(i18n("Font Settings")); setPagePixmap("fonts"); TQGroupBox *box = new TQGroupBox(0, Qt::Vertical, i18n("Fonts Embedding"), this); TQGroupBox *box2 = new TQGroupBox(0, Qt::Vertical, i18n("Fonts Path"), this); m_embedfonts = new TQCheckBox(i18n("&Embed fonts in PostScript data when printing"), box); m_fontpath = new TDEListView(box2); m_fontpath->addColumn(""); m_fontpath->header()->setStretchEnabled(true, 0); m_fontpath->header()->hide(); m_fontpath->setSorting(-1); m_addpath = new KURLRequester(box2); m_addpath->setMode(KFile::Directory|KFile::ExistingOnly|KFile::LocalOnly); m_up = new KPushButton(KGuiItem(i18n("&Up"), "up"), box2); m_down = new KPushButton(KGuiItem(i18n("&Down"), "down"), box2); m_add = new KPushButton(KGuiItem(i18n("&Add"), "add"), box2); m_remove = new KPushButton(KGuiItem(i18n("&Remove"), "editdelete"), box2); TQLabel *lab0 = new TQLabel(i18n("Additional director&y:"), box2); lab0->setBuddy(m_addpath); TQVBoxLayout *l0 = new TQVBoxLayout(TQT_TQLAYOUT(box->layout()), KDialog::spacingHint()); l0->addWidget(m_embedfonts); TQVBoxLayout *l1 = new TQVBoxLayout(TQT_TQLAYOUT(box2->layout()), KDialog::spacingHint()); l1->addWidget(m_fontpath); TQHBoxLayout *l2 = new TQHBoxLayout(0, 0, KDialog::spacingHint()); l1->addLayout(l2); l2->addWidget(m_up); l2->addWidget(m_down); l2->addWidget(m_remove); l1->addSpacing(10); l1->addWidget(lab0); l1->addWidget(m_addpath); TQHBoxLayout *l3 = new TQHBoxLayout(0, 0, KDialog::spacingHint()); l1->addLayout(l3); l3->addStretch(1); l3->addWidget(m_add); TQVBoxLayout *l4 = new TQVBoxLayout(this, 0, KDialog::spacingHint()); l4->addWidget(box); l4->addWidget(box2); TQWhatsThis::add(m_embedfonts, i18n("These options will automatically put fonts in the PostScript file " "which are not present on the printer. Font embedding usually produces better print results " "(closer to what you see on the screen), but larger print data as well.")); TQWhatsThis::add(m_fontpath, i18n("When using font embedding you can select additional directories where " "KDE should search for embeddable font files. By default, the X server " "font path is used, so adding those directories is not needed. The default " "search path should be sufficient in most cases.")); connect(m_remove, TQT_SIGNAL(clicked()), TQT_SLOT(slotRemove())); connect(m_add, TQT_SIGNAL(clicked()), TQT_SLOT(slotAdd())); connect(m_up, TQT_SIGNAL(clicked()), TQT_SLOT(slotUp())); connect(m_down, TQT_SIGNAL(clicked()), TQT_SLOT(slotDown())); connect(m_fontpath, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotSelected())); connect(m_addpath, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(slotTextChanged(const TQString&))); m_add->setEnabled(false); m_remove->setEnabled(false); m_up->setEnabled(false); m_down->setEnabled(false); }
void KHelpMain::createMenu() { KStdAccel stdAccel; fileMenu = new QPopupMenu; CHECK_PTR( fileMenu ); fileMenu->insertItem( klocale->translate("&New Help Window"), this, SLOT( slotCloneWindow() ), stdAccel.openNew() ); fileMenu->insertSeparator(); fileMenu->insertItem( klocale->translate("&Open File..."), helpwin, SLOT(slotOpenFile()), stdAccel.open() ); // fileMenu->insertItem( klocale->translate("Open UR&L..."), helpwin, // SLOT(slotOpenURL()) ); fileMenu->insertItem( klocale->translate("&Reload"), helpwin, SLOT(slotReload()) ); fileMenu->insertSeparator(); fileMenu->insertItem( klocale->translate("&Search"), helpwin, SLOT(slotSearch()) ); fileMenu->insertSeparator(); fileMenu->insertItem( klocale->translate("&Print..."), helpwin, SLOT(slotPrint()), stdAccel.print() ); fileMenu->insertSeparator(); idClose = fileMenu->insertItem(klocale->translate("&Close"),this, SLOT(slotClose()), stdAccel.close()); // CC :!!!!! fileMenu->insertItem( klocale->translate("&Quit"), this, SLOT(slotQuit()), stdAccel.quit() ); editMenu = new QPopupMenu; CHECK_PTR( editMenu ); idCopy = editMenu->insertItem(klocale->translate("&Copy"), helpwin, SLOT(slotCopy()), stdAccel.copy() ); editMenu->insertItem(klocale->translate("&Find..."), helpwin, SLOT(slotFind()), stdAccel.find() ); editMenu->insertItem(klocale->translate("Find &next"), helpwin, SLOT(slotFindNext()), Key_F3 ); gotoMenu = new QPopupMenu; CHECK_PTR( gotoMenu ); idBack = gotoMenu->insertItem( klocale->translate("&Back"), helpwin, SLOT(slotBack()) ); idForward = gotoMenu->insertItem( klocale->translate("&Forward"), helpwin, SLOT(slotForward()) ); gotoMenu->insertSeparator(); idDir = gotoMenu->insertItem( klocale->translate("&Contents"), helpwin, SLOT(slotDir()) ); idTop = gotoMenu->insertItem( klocale->translate("&Top"), helpwin, SLOT(slotTop()) ); idUp = gotoMenu->insertItem( klocale->translate("&Up"), helpwin, SLOT(slotUp()) ); idPrev = gotoMenu->insertItem( klocale->translate("&Previous"), helpwin, SLOT(slotPrev()) ); idNext = gotoMenu->insertItem( klocale->translate("&Next"), helpwin, SLOT(slotNext()) ); bookmarkMenu = new QPopupMenu; CHECK_PTR( bookmarkMenu ); connect( bookmarkMenu, SIGNAL( activated( int ) ), helpwin, SLOT( slotBookmarkSelected( int ) ) ); connect( bookmarkMenu, SIGNAL( highlighted( int ) ), helpwin, SLOT( slotBookmarkHighlighted( int ) ) ); optionsMenu = new QPopupMenu; CHECK_PTR( optionsMenu ); optionsMenu->setCheckable( true ); optionsMenu->insertItem( klocale->translate("&General Preferences..."), this, SLOT(slotOptionsGeneral()) ); optionsMenu->insertSeparator(); optionsMenu->insertItem(klocale->translate( "Show &Toolbar"), this, SLOT(slotOptionsToolbar())); optionsMenu->insertItem( klocale->translate("Show &Location"), this, SLOT(slotOptionsLocation()) ); optionsMenu->insertItem( klocale->translate("Show Status&bar"), this, SLOT(slotOptionsStatusbar()) ); optionsMenu->insertSeparator(); optionsMenu->insertItem( klocale->translate("&Save Options"), this, SLOT(slotOptionsSave()) ); QString at = klocale->translate("KDE Help System\n"); at+= klocale->translate("Version "); at+= KDEHELP_VERSION; at+=klocale->translate("\n\nCopyright (c) 1997 Martin Jones <*****@*****.**>"\ "\n\nThis program is licensed under the GNU General Public License (GPL)."\ "\nKDEHelp comes with ABSOLUTELY NO WARRANY to the extent permitted by applicable law."); QPopupMenu *helpMenu = kapp->getHelpMenu( true, at ); /* QPopupMenu *helpMenu = new QPopupMenu; CHECK_PTR( helpMenu ); helpMenu->insertItem( klocale->translate("&Using KDE Help"), this, SLOT(slotUsingHelp()) ); helpMenu->insertSeparator(); helpMenu->insertItem( klocale->translate("&About"), this, SLOT(slotAbout()) ); */ menu = new KMenuBar( this ); CHECK_PTR( menu ); menu->insertItem( klocale->translate("&File"), fileMenu ); menu->insertItem( klocale->translate("&Edit"), editMenu ); menu->insertItem( klocale->translate("&Goto"), gotoMenu ); menu->insertItem( klocale->translate("&Bookmarks"), bookmarkMenu ); menu->insertItem( klocale->translate("&Options"), optionsMenu ); menu->insertSeparator(); menu->insertItem( klocale->translate("&Help"), helpMenu ); }
PrefsWages::PrefsWages(QWidget* parent) : QWidget(parent) { QVBoxLayout *vboxLay = new QVBoxLayout; mWagesModel = new QSqlTableModel(this); mWagesModel->setTable("stdSaetze"); mWagesModel->setSort(3, Qt::AscendingOrder); mWagesModel->setEditStrategy(QSqlTableModel::OnManualSubmit); mWagesModel->select(); mWagesModel->setHeaderData(0, Qt::Horizontal, tr("ID")); mWagesModel->setHeaderData(1, Qt::Horizontal, tr("Code")); mWagesModel->setHeaderData(2, Qt::Horizontal, tr("Price")); mWagesModel->setHeaderData(3, Qt::Horizontal, tr("Sortkey")); mProxyModel = new QSortFilterProxyModel(this); mProxyModel->setSourceModel(mWagesModel); mWagesTreeView = new ImpTreeView; vboxLay->addWidget( mWagesTreeView ); mWagesTreeView->setModel(mProxyModel); mWagesTreeView->setItemDelegate(new WagesItemDelegate()); mWagesTreeView->hideColumn(0); mWagesTreeView->hideColumn(3); mWagesTreeView->header()->stretchLastSection(); mWagesTreeView->setColumnWidth(1, 200); mWagesTreeView->resizeColumnToContents(2); mWagesTreeView->resizeColumnToContents(1); mWagesTreeView->setEditTriggers(ImpTreeView::NoEditTriggers); connect( mWagesTreeView, SIGNAL(clicked(QModelIndex)), SLOT( slotWageSelected(QModelIndex) ) ); connect( mWagesTreeView, SIGNAL(doubleClicked(QModelIndex)), SLOT(slotEditWage(QModelIndex))); QHBoxLayout *butLay = new QHBoxLayout; butLay->addStretch( 1 ); mUp = new KPushButton( KIcon("arrow-up"), i18n( "Up" )); connect( mUp, SIGNAL( clicked() ), SLOT( slotUp() ) ); butLay->addWidget( mUp ); mUp->setEnabled(false); mDown = new KPushButton( KIcon("arrow-down"), i18n( "Down" )); connect( mDown, SIGNAL( clicked() ), SLOT( slotDown() ) ); butLay->addWidget( mDown ); mDown->setEnabled(false); KPushButton *but = new KPushButton( KIcon("list-add"), i18n( "Add" )); connect( but, SIGNAL( clicked() ), SLOT( slotAddWage() ) ); butLay->addWidget( but ); mEditWage = new KPushButton( KIcon("document-edit"), i18n( "Edit" )); connect( mEditWage, SIGNAL( clicked() ), SLOT( slotEditWage() ) ); butLay->addWidget( mEditWage ); mEditWage->setEnabled(false); mDelWage = new KPushButton( KIcon("list-remove"), i18n( "Remove" ) ); connect( mDelWage, SIGNAL( clicked() ), SLOT( slotDeleteWage() ) ); butLay->addWidget( mDelWage ); mDelWage->setEnabled( false ); vboxLay->addLayout( butLay ); this->setLayout( vboxLay ); }
KfmView::KfmView( KfmGui *_gui, QWidget *parent, const char *name, KfmView *_parent_view ) : KHTMLView( parent, name, 0, _parent_view ) { rectStart = false; dPainter = 0L; htmlCache = new HTMLCache(); if(!_parent_view) { backStack = new QStack<SavedPage>; forwardStack = new QStack<SavedPage>; backStack->setAutoDelete( false ); forwardStack->setAutoDelete( false ); } else { backStack = _parent_view->getBackStack(); forwardStack = _parent_view->getForwardStack(); } connect( htmlCache, SIGNAL( urlLoaded( const char*, const char *) ), this, SLOT( slotImageLoaded( const char*, const char* ) ) ); connect( this, SIGNAL( imageRequest( const char * ) ), htmlCache, SLOT( slotURLRequest( const char * ) ) ); connect( this, SIGNAL( cancelImageRequest( const char * ) ), htmlCache, SLOT( slotCancelURLRequest( const char * ) ) ); connect( this, SIGNAL( popupMenu( KHTMLView *, const char *, const QPoint & ) ), this, SLOT( slotPopupMenu2( KHTMLView *, const char *, const QPoint & ) ) ); connect( getKHTMLWidget(), SIGNAL( scrollVert( int ) ), SLOT( slotUpdateSelect(int) ) ); connect( this, SIGNAL( goUp() ), this, SLOT( slotUp() ) ); connect( this, SIGNAL( goRight() ), this, SLOT( slotForward() ) ); connect( this, SIGNAL( goLeft() ), this, SLOT( slotBack() ) ); connect ( getKHTMLWidget(), SIGNAL( redirect( int , const char *) ), this, SLOT( slotRedirect( int, const char * )) ); connect( &redirectTimer, SIGNAL(timeout()), this, SLOT(slotDelayedRedirect2())); gui = _gui; dropZone = 0L; popupMenu = 0L; popupMenuEvent = false; stackLock = false; // ignoreMouseRelease = false; // Stephan: Just guessed. It was undefined childViewList.setAutoDelete( false ); manager = new KFMManager( this ); dropZone = new KDNDDropZone( view , DndURL ); connect( dropZone, SIGNAL( dropAction( KDNDDropZone *) ), this, SLOT( slotDropEvent( KDNDDropZone *) ) ); connect( dropZone, SIGNAL( dropEnter( KDNDDropZone *) ), this, SLOT( slotDropEnterEvent( KDNDDropZone *) ) ); connect( dropZone, SIGNAL( dropLeave( KDNDDropZone *) ), this, SLOT( slotDropLeaveEvent( KDNDDropZone *) ) ); connect( KIOServer::getKIOServer(), SIGNAL( notify( const char * ) ), this, SLOT( slotFilesChanged( const char * ) ) ); connect( KIOServer::getKIOServer(), SIGNAL( mountNotify() ), this, SLOT( slotMountNotify() ) ); getKHTMLWidget()->setFocusPolicy( QWidget::StrongFocus ); setHTMLWidgetOptions(); }