Commit 55ac86f0 authored by Claudio Cambra's avatar Claudio Cambra
Browse files

Reduce minimum size of incidences in hourly views

parent 262022ec
Pipeline #168470 failed with stage
in 2 minutes and 36 seconds
......@@ -191,7 +191,7 @@ QVariantList HourlyIncidenceModel::layoutLines(const QDateTime &rowStart) const
// We get a start position relative to the number of period spaces there are in a day
const auto start = ((startDT.time().hour() * 1.0) * (60.0 / mPeriodLength)) + ((startDT.time().minute() * 1.0) / mPeriodLength);
auto duration = // Give a minimum acceptable height or otherwise have unclickable incidence
qMax(getDuration(startDT, idx.data(IncidenceOccurrenceModel::EndTime).toDateTime().toTimeZone(QTimeZone::systemTimeZone()), mPeriodLength), 2.5);
qMax(getDuration(startDT, idx.data(IncidenceOccurrenceModel::EndTime).toDateTime().toTimeZone(QTimeZone::systemTimeZone()), mPeriodLength), 1.0);
if (start + duration > periodsPerDay) {
duration = periodsPerDay - start + 1;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment