Skip to content
This repository has been archived by the owner on Feb 12, 2023. It is now read-only.

Commit

Permalink
fix: Use epsilon to compare float
Browse files Browse the repository at this point in the history
Fix #2394 (5)
  • Loading branch information
Diadlo committed Nov 26, 2017
1 parent a96fbf1 commit 91dabf1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/video/videosurface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ void VideoSurface::onNewFrameAvailable(const std::shared_ptr<VideoFrame>& newFra

float newRatio = getSizeRatio(newSize);

if (newRatio != ratio && isVisible()) {
if (qAbs(newRatio - ratio) < 1E-3 && isVisible()) {
ratio = newRatio;
recalulateBounds();
emit ratioChanged();
Expand Down
2 changes: 1 addition & 1 deletion src/widget/groupwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -260,5 +260,5 @@ void GroupWidget::setName(const QString& name)

void GroupWidget::retranslateUi()
{
updatePeerCount();
updateUserCount();
}

0 comments on commit 91dabf1

Please sign in to comment.