diff options
author | mio <stigma@disroot.org> | 2024-08-22 19:34:23 +1000 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-08-22 23:12:08 +0900 |
commit | bca2a1a170c5030aeb55b411fd64a4adf02e3434 (patch) | |
tree | 66769d4d979fffce4e2f64316df5dd81fa2de795 /src/app/mainWindow.cpp | |
parent | 55214aea7cf8d37849d1566535a4f13eb04f2528 (diff) | |
download | codeine-bca2a1a170c5030aeb55b411fd64a4adf02e3434.tar.gz codeine-bca2a1a170c5030aeb55b411fd64a4adf02e3434.zip |
Use nullptr instead of NULL/0 pointer in C++ files
See: https://mirror.git.trinitydesktop.org/gitea/TDE/tde/issues/73
Signed-off-by: mio <stigma@disroot.org>
(cherry picked from commit ed55bf072682ebf73239e74b7e3dd286ed5616a5)
Diffstat (limited to 'src/app/mainWindow.cpp')
-rw-r--r-- | src/app/mainWindow.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/app/mainWindow.cpp b/src/app/mainWindow.cpp index 1eb27f5..ee92f7c 100644 --- a/src/app/mainWindow.cpp +++ b/src/app/mainWindow.cpp @@ -116,7 +116,8 @@ MainWindow::MainWindow() } { - TQPopupMenu *menu = 0, *settings = static_cast<TQPopupMenu*>(factory()->container( "settings", this )); + TQPopupMenu *menu = nullptr; + TQPopupMenu *settings = static_cast<TQPopupMenu*>(factory()->container( "settings", this )); int id = SubtitleChannelsMenuItemId, index = 0; #define make_menu( name, text ) \ @@ -263,7 +264,7 @@ MainWindow::setupActions() new TDEAction( i18n("Video Settings..."), "configure", Key_V, this, TQ_SLOT(configure()), ac, "video_settings" ); new TDEAction( i18n("Configure xine..."), "configure", 0, this, TQ_SLOT(configure()), ac, "xine_settings" ); - (new KWidgetAction( m_positionSlider, i18n("Position Slider"), 0, 0, 0, ac, "position_slider" ))->setAutoSized( true ); + (new KWidgetAction( m_positionSlider, i18n("Position Slider"), nullptr, nullptr, nullptr, ac, "position_slider" ))->setAutoSized( true ); m_volumeAction = new VolumeAction( toolBar(), ac ); } @@ -381,7 +382,7 @@ MainWindow::load( const KURL &url ) if (url.protocol() == "media") { #define UDS_LOCAL_PATH (72 | TDEIO::UDS_STRING) TDEIO::UDSEntry e; - if (!TDEIO::NetAccess::stat( url, e, 0 )) + if (!TDEIO::NetAccess::stat( url, e, nullptr )) MessageBox::sorry( "There was an internal error with the media slave..." ); else { TDEIO::UDSEntry::ConstIterator end = e.end(); @@ -571,7 +572,7 @@ MainWindow::fullScreenToggled( bool isFullScreen ) delete s_handler; // prevent videoWindow() moving around when mouse moves - setCentralWidget( isFullScreen ? 0 : videoWindow() ); + setCentralWidget( isFullScreen ? nullptr : videoWindow() ); } void @@ -626,7 +627,7 @@ void MainWindow::aboutToShowMenu() { TQPopupMenu *menu = (TQPopupMenu*)sender(); - TQCString name( sender() ? sender()->name() : 0 ); + TQCString name( sender() ? sender()->name() : nullptr ); // uncheck all items first for( uint x = 0; x < menu->count(); ++x ) @@ -701,9 +702,9 @@ action( const char *name ) { #define QT_FATAL_ASSERT - MainWindow *mainWindow = 0; - TDEActionCollection *actionCollection = 0; - TDEAction *action = 0; + MainWindow *mainWindow = nullptr; + TDEActionCollection *actionCollection = nullptr; + TDEAction *action = nullptr; if( mainWindow = (MainWindow*)kapp->mainWidget() ) if( actionCollection = mainWindow->actionCollection() ) |