mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-23 20:14:05 +00:00
[autofix.ci] apply automated fixes
This commit is contained in:
parent
48fc8fceff
commit
1724b4f32b
|
@ -73,7 +73,7 @@ void ExternalAudioPlayer::onViewerDestroyed( QObject * destroyedViewer )
|
|||
}
|
||||
}
|
||||
else if ( viewer.get() == destroyedViewer )
|
||||
viewer.reset(nullptr); // viewer finished and died -> reset
|
||||
viewer.reset( nullptr ); // viewer finished and died -> reset
|
||||
}
|
||||
|
||||
QString ExternalAudioPlayer::startViewer()
|
||||
|
|
|
@ -35,11 +35,11 @@ private:
|
|||
|
||||
struct QObjectDeleteLater
|
||||
{
|
||||
void operator()( QObject * p )
|
||||
{
|
||||
if ( p )
|
||||
p->deleteLater();
|
||||
}
|
||||
void operator()( QObject * p )
|
||||
{
|
||||
if ( p )
|
||||
p->deleteLater();
|
||||
}
|
||||
};
|
||||
// deleteLater() is safer because viewer actively participates in the QEventLoop.
|
||||
std::unique_ptr< ExternalViewer, QObjectDeleteLater > viewer;
|
||||
|
|
Loading…
Reference in a new issue