153
153
// create main view and actions
154
154
setMainWidget(d->mainwidget_);
156
KStdAction::close(this, SLOT(reject()), d->actions_, "close_print");
156
d->actions_->addAction(KStandardAction::Close, "close_print", this, SLOT(reject()));
159
159
KAction *action = 0;
160
action = new KAction(i18n("Print"), d->actions_, "continue_print");
161
action->setIcon( KIcon( "fileprint" ) );
162
action->setShortcut( Qt::Key_Return );
163
connect( action, SIGNAL( triggered( bool ) ), this, SLOT(accept()) );
165
action = new KAction(i18n("Print"), d->actions_, "continue_print");
166
action->setIcon( KIcon( "fileprint" ) );
167
action->setShortcut( Qt::Key_Return );
168
connect( action, SIGNAL( triggered( bool ) ), this, SLOT(accept()) );
170
action = new KAction(i18n("Cancel"), d->actions_, "stop_print");
160
action = new KAction(i18n("Print"), this);
161
d->actions_->addAction( "continue_print", action );
162
action->setIcon( KIcon( "fileprint" ) );
163
action->setShortcut( QKeySequence(Qt::Key_Return) );
164
connect( action, SIGNAL( triggered( bool ) ), this, SLOT(accept()) );
166
action = new KAction(i18n("Print"), this);
167
d->actions_->addAction( "continue_print", action );
168
action->setIcon( KIcon( "fileprint" ) );
169
action->setShortcut( QKeySequence(Qt::Key_Return) );
170
connect( action, SIGNAL( triggered( bool ) ), this, SLOT(accept()) );
172
action = new KAction(i18n("Cancel"), this);
173
d->actions_->addAction( "stop_print", action );
171
174
action->setIcon( KIcon( "stop" ) );
172
action->setShortcut( Qt::Key_Escape );
175
action->setShortcut( QKeySequence(Qt::Key_Escape) );
173
176
connect( action, SIGNAL( triggered( bool ) ), this, SLOT(reject()) );
205
208
QDomElement a = acts.item( i ).toElement();
206
209
if ( a.attribute( "name" ) == "goToPage" )
208
KAction *act = d->gvpart_->action( a );
211
QAction *act = d->gvpart_->action( a );
210
213
d->plugAction( act );
215
218
d->toolbar_->insertLineSeparator();
216
219
if ((act = d->gvpart_->action("zoomIn")) != 0)
217
220
d->plugAction(act);
332
335
else if (!previewOnly)
334
return (KMessageBox::questionYesNo(parentW, i18n("Do you want to continue printing?"), QString(), KGuiItem(i18n("Print"),"fileprint"), KStdGuiItem::cancel(), "continuePrinting") == KMessageBox::Yes);
337
return (KMessageBox::questionYesNo(parentW, i18n("Do you want to continue printing?"), QString(), KGuiItem(i18n("Print"),"fileprint"), KStandardGuiItem::cancel(), "continuePrinting") == KMessageBox::Yes);