mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-30 22:25:12 +00:00
Use gsl::finally() instead of base::scope_guard().
This commit is contained in:
@@ -247,7 +247,7 @@ QString GetServerName() {
|
||||
}
|
||||
|
||||
gchar *name = nullptr;
|
||||
auto guard = base::scope_guard([&name] {
|
||||
auto guard = gsl::finally([&name] {
|
||||
if (name) Libs::g_free(name);
|
||||
});
|
||||
|
||||
|
@@ -659,7 +659,7 @@ int32 MainWindow::screenNameChecksum(const QString &name) const {
|
||||
|
||||
void MainWindow::psRefreshTaskbarIcon() {
|
||||
auto refresher = object_ptr<QWidget>(this);
|
||||
auto guard = base::scope_guard([&refresher] {
|
||||
auto guard = gsl::finally([&refresher] {
|
||||
refresher.destroy();
|
||||
});
|
||||
refresher->setWindowFlags(static_cast<Qt::WindowFlags>(Qt::Tool) | Qt::FramelessWindowHint);
|
||||
|
Reference in New Issue
Block a user