fix some easy krazy issues

svn path=/trunk/KDE/kdegraphics/okular/; revision=654317
This commit is contained in:
Albert Astals Cid 2007-04-15 19:11:10 +00:00
parent 29e8bbc50f
commit b0339a4e40
11 changed files with 20 additions and 20 deletions

View file

@ -83,7 +83,7 @@ class OKULAR_EXPORT Document : public QObject
/**
* Creates a new document with the given @p widget as widget to relay GUI things (messageboxes, ...).
*/
Document( QWidget *widget );
explicit Document( QWidget *widget );
/**
* Destroys the document.

View file

@ -116,7 +116,7 @@ class OKULAR_EXPORT DocumentObserver
private:
class Private;
Private* d;
const Private* d;
};
}

View file

@ -73,7 +73,7 @@ class OKULAR_EXPORT TextEntity
NormalizedRect* m_transformed_area;
class Private;
Private *d;
const Private *d;
Q_DISABLE_COPY( TextEntity )
};

View file

@ -718,7 +718,7 @@ bool Part::openFile()
if ( m_document->metaData( "StartFullScreen" ).toBool() || m_cliPresentation )
{
if ( !m_cliPresentation )
KMessageBox::information( m_presentationWidget, i18n("The document is going to be launched on presentation mode because the file requested it."), QString::null, "autoPresentationWarning" );
KMessageBox::information( m_presentationWidget, i18n("The document is going to be launched on presentation mode because the file requested it."), QString(), "autoPresentationWarning" );
m_cliPresentation = false;
QMetaObject::invokeMethod(this, "slotShowPresentation", Qt::QueuedConnection);
}
@ -819,13 +819,13 @@ void Part::close()
{
closeUrl();
}
else KMessageBox::information( widget(), i18n( "This link points to a close document action that does not work when using the embedded viewer." ), QString::null, "warnNoCloseIfNotInOkular" );
else KMessageBox::information( widget(), i18n( "This link points to a close document action that does not work when using the embedded viewer." ), QString(), "warnNoCloseIfNotInOkular" );
}
void Part::cannotQuit()
{
KMessageBox::information( widget(), i18n( "This link points to a quit application action that does not work when using the embedded viewer." ), QString::null, "warnNoQuitIfNotInOkular" );
KMessageBox::information( widget(), i18n( "This link points to a quit application action that does not work when using the embedded viewer." ), QString(), "warnNoQuitIfNotInOkular" );
}
@ -1098,12 +1098,12 @@ void Part::slotFindNext()
void Part::slotSaveFileAs()
{
KUrl saveUrl = KFileDialog::getSaveUrl( url().isLocalFile() ? url().url() : url().fileName(), QString::null, widget() );
KUrl saveUrl = KFileDialog::getSaveUrl( url().isLocalFile() ? url().url() : url().fileName(), QString(), widget() );
if ( saveUrl.isValid() && !saveUrl.isEmpty() )
{
if ( KIO::NetAccess::exists( saveUrl, false, widget() ) )
{
if (KMessageBox::warningContinueCancel( widget(), i18n("A file named \"%1\" already exists. Are you sure you want to overwrite it?", saveUrl.fileName()), QString::null, KGuiItem(i18n("Overwrite"))) != KMessageBox::Continue)
if (KMessageBox::warningContinueCancel( widget(), i18n("A file named \"%1\" already exists. Are you sure you want to overwrite it?", saveUrl.fileName()), QString(), KGuiItem(i18n("Overwrite"))) != KMessageBox::Continue)
return;
}
@ -1341,7 +1341,7 @@ void Part::slotExportAs(QAction * act)
return;
QString filter = id == 0 ? "text/plain" : m_exportFormats.at( id - 1 ).mimeType()->name();
QString fileName = KFileDialog::getSaveFileName( url().isLocalFile() ? url().fileName() : QString::null, filter, widget() );
QString fileName = KFileDialog::getSaveFileName( url().isLocalFile() ? url().fileName() : QString(), filter, widget() );
if ( !fileName.isEmpty() )
{
bool saved = id == 0 ? m_document->exportToText( fileName ) : m_document->exportTo( fileName, m_exportFormats.at( id - 1 ) );

View file

@ -41,7 +41,7 @@ public:
/**
* Constructor
*/
Shell(KCmdLineArgs* args = 0, const KUrl &url = KUrl());
explicit Shell(KCmdLineArgs* args = 0, const KUrl &url = KUrl());
/**
* Default Destructor

View file

@ -30,7 +30,7 @@ class BookmarkList : public QWidget, public Okular::DocumentObserver
Q_OBJECT
public:
BookmarkList( Okular::Document *document, QWidget *parent = 0 );
explicit BookmarkList( Okular::Document *document, QWidget *parent = 0 );
~BookmarkList();
// inherited from DocumentObserver

View file

@ -81,7 +81,7 @@ void EmbeddedFilesDialog::saveFile()
if (!path.isEmpty())
{
QFile f(path);
if (!f.exists() || KMessageBox::warningContinueCancel( this, i18n("A file named \"%1\" already exists. Are you sure you want to overwrite it?", path), QString::null, KGuiItem(i18n("Overwrite"))) == KMessageBox::Continue)
if (!f.exists() || KMessageBox::warningContinueCancel( this, i18n("A file named \"%1\" already exists. Are you sure you want to overwrite it?", path), QString(), KGuiItem(i18n("Overwrite"))) == KMessageBox::Continue)
{
f.open(QIODevice::WriteOnly);
f.write(ef->data());

View file

@ -25,7 +25,7 @@ class FindBar
Q_OBJECT
public:
FindBar( Okular::Document * document, QWidget * parent = 0 );
explicit FindBar( Okular::Document * document, QWidget * parent = 0 );
virtual ~FindBar();
QString text() const;

View file

@ -57,7 +57,7 @@ class FormLineEdit : public QLineEdit, public FormWidgetIface
Q_OBJECT
public:
FormLineEdit( Okular::FormFieldText * text, QWidget * parent = 0 );
explicit FormLineEdit( Okular::FormFieldText * text, QWidget * parent = 0 );
private slots:
void textEdited( const QString& );
@ -71,7 +71,7 @@ class TextAreaEdit : public KTextEdit, public FormWidgetIface
Q_OBJECT
public:
TextAreaEdit( Okular::FormFieldText * text, QWidget * parent = 0 );
explicit TextAreaEdit( Okular::FormFieldText * text, QWidget * parent = 0 );
private slots:
void slotChanged();
@ -86,7 +86,7 @@ class FileEdit : public KUrlRequester, public FormWidgetIface
Q_OBJECT
public:
FileEdit( Okular::FormFieldText * text, QWidget * parent = 0 );
explicit FileEdit( Okular::FormFieldText * text, QWidget * parent = 0 );
private slots:
void slotChanged( const QString& );
@ -101,7 +101,7 @@ class ListEdit : public QListWidget, public FormWidgetIface
Q_OBJECT
public:
ListEdit( Okular::FormFieldChoice * choice, QWidget * parent = 0 );
explicit ListEdit( Okular::FormFieldChoice * choice, QWidget * parent = 0 );
private slots:
void selectionChanged();
@ -116,7 +116,7 @@ class ComboEdit : public QComboBox, public FormWidgetIface
Q_OBJECT
public:
ComboEdit( Okular::FormFieldChoice * choice, QWidget * parent = 0 );
explicit ComboEdit( Okular::FormFieldChoice * choice, QWidget * parent = 0 );
private slots:
void indexChanged( int );

View file

@ -157,7 +157,7 @@ class PickPointEngine : public AnnotatorEngine
//note dialog
QString prompt = i18n( "Please input the free text:" ) ;
bool resok;
QString note = KInputDialog::getMultiLineText( i18n( "Free Text" ), prompt, QString::null, &resok );
QString note = KInputDialog::getMultiLineText( i18n( "Free Text" ), prompt, QString(), &resok );
if(resok)
{
//add note

View file

@ -1040,7 +1040,7 @@ void PresentationWidget::slotTransitionStep()
void PresentationWidget::slotDelayedEvents()
{
// inform user on how to exit from presentation mode
KMessageBox::information( this, i18n("There are two ways of exiting presentation mode, you can press either ESC key or click with the quit button that appears when placing the mouse in the top-right corner. Of course you can cycle windows (Alt+TAB by default)"), QString::null, "presentationInfo" );
KMessageBox::information( this, i18n("There are two ways of exiting presentation mode, you can press either ESC key or click with the quit button that appears when placing the mouse in the top-right corner. Of course you can cycle windows (Alt+TAB by default)"), QString(), "presentationInfo" );
}
void PresentationWidget::slotPageChanged()