Use arc_angles.h from lib_ui.

This commit is contained in:
John Preston 2024-05-03 11:50:44 +04:00
parent da31fef1ae
commit 68df8448a2
3 changed files with 4 additions and 18 deletions

View file

@ -509,7 +509,10 @@ void Location::paintLiveRemaining(
auto pen = QPen(color);
pen.setWidthF(stroke);
p.setPen(pen);
p.drawArc(rect, 90 * 16, int(base::SafeRound(360 * 16 * progress)));
p.drawArc(
rect,
arc::kQuarterLength,
int(base::SafeRound(arc::kFullLength * progress)));
}
p.setPen(stm->msgServiceFg);

View file

@ -1,16 +0,0 @@
/*
This file is part of Telegram Desktop,
the official desktop application for the Telegram messaging service.
For license and copyright information please follow this link:
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
*/
#pragma once
namespace arc {
constexpr auto kFullLength = 360 * 16;
constexpr auto kQuarterLength = (kFullLength / 4);
constexpr auto kHalfLength = (kFullLength / 2);
} // namespace arc

View file

@ -396,7 +396,6 @@ PRIVATE
ui/widgets/vertical_drum_picker.cpp
ui/widgets/vertical_drum_picker.h
ui/arc_angles.h
ui/cached_round_corners.cpp
ui/cached_round_corners.h
ui/color_contrast.cpp