mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-02-25 10:01:00 +00:00
Use setFixedSize instead of set{Minimum,Maximum}Size combo
This commit is contained in:
parent
cfc254bd90
commit
0f9d83f34b
@ -610,14 +610,10 @@ NotificationsCount::SampleWidget::SampleWidget(
|
||||
const QPixmap &cache)
|
||||
: _owner(owner)
|
||||
, _cache(cache) {
|
||||
const QSize size(
|
||||
setFixedSize(
|
||||
cache.width() / cache.devicePixelRatio(),
|
||||
cache.height() / cache.devicePixelRatio());
|
||||
|
||||
resize(size);
|
||||
setMinimumSize(size);
|
||||
setMaximumSize(size);
|
||||
|
||||
setWindowFlags(Qt::WindowFlags(Qt::FramelessWindowHint)
|
||||
| Qt::WindowStaysOnTopHint
|
||||
| Qt::BypassWindowManagerHint
|
||||
|
@ -586,9 +586,8 @@ void Widget::addToHeight(int add) {
|
||||
}
|
||||
|
||||
void Widget::updateGeometry(int x, int y, int width, int height) {
|
||||
setGeometry(x, y, width, height);
|
||||
setMinimumSize(QSize(width, height));
|
||||
setMaximumSize(QSize(width, height));
|
||||
move(x, y);
|
||||
setFixedSize(width, height);
|
||||
update();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user