Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
crsib committed Feb 21, 2024
1 parent 95da758 commit e726e97
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions modules/mod-cloud-audiocom/ui/dialogs/ProjectsListDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,11 @@ class ProjectsListDialog::ProjectsTableData final : public wxGridTableBase
return XO("less than 1 minute").Translation();
if (time_passed < hours(1))
return XP("one minutes ago", "%d minutes ago",
0)(duration_cast<minutes>(time_passed).count())
0)(static_cast<int>(duration_cast<minutes>(time_passed).count()))
.Translation();
if (time_passed < hours(48))
return XP("one hour ago", "%d hours ago",
0)(duration_cast<hours>(time_passed).count())
0)(static_cast<int>(duration_cast<hours>(time_passed).count()))
.Translation();

return wxDateTime(static_cast<time_t>(time)).Format();
Expand Down Expand Up @@ -222,7 +222,7 @@ class ProjectsListDialog::ProjectsTableData final : public wxGridTableBase
return mResponse.Pagination.PagesCount;
}

std::string_view GetSelectedProjectId() const
std::string GetSelectedProjectId() const
{
const auto selectedRow = mOwner.mProjectsTable->GetSelectedRows();

Expand Down Expand Up @@ -382,7 +382,9 @@ void ProjectsListDialog::OnOpen()

EndModal(wxID_OK);

OpenProjectFromCloud(mProject, selectedProjectId, {}, false);
BasicUI::CallAfter([project = mProject, selectedProjectId] {
OpenProjectFromCloud(project, selectedProjectId, {}, false);
});
}

} // namespace cloud::audiocom::sync

0 comments on commit e726e97

Please sign in to comment.