| 172 | } |
| 173 | |
| 174 | void SessionItemWidgetPrivate::initUI() |
| 175 | { |
| 176 | q->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum); |
| 177 | QVBoxLayout *mainLayout = new QVBoxLayout(q); |
| 178 | mainLayout->setContentsMargins(0, 0, 0, 0); |
| 179 | mainLayout->setSpacing(0); |
| 180 | |
| 181 | headerLine = new ArrowHeaderLine(q); |
| 182 | contentLoader = new ContentBox(q); |
| 183 | contentLoader->setFixedHeight(0); |
| 184 | |
| 185 | boxWidget = new DVBoxWidget(q); |
| 186 | auto contentLayout = boxWidget->layout(); |
| 187 | contentLayout->addWidget(createContent()); |
| 188 | |
| 189 | QVBoxLayout *loaderLayout = new QVBoxLayout(contentLoader); |
| 190 | loaderLayout->setMargin(0); |
| 191 | loaderLayout->setSpacing(0); |
| 192 | loaderLayout->addWidget(boxWidget); |
| 193 | loaderLayout->addStretch(); |
| 194 | |
| 195 | animation = new QPropertyAnimation(contentLoader, "height", q); |
| 196 | animation->setDuration(200); |
| 197 | animation->setEasingCurve(QEasingCurve::InSine); |
| 198 | |
| 199 | mainLayout->addWidget(headerLine); |
| 200 | mainLayout->addWidget(contentLoader); |
| 201 | } |
| 202 | |
| 203 | void SessionItemWidgetPrivate::initConnection() |
| 204 | { |
no test coverage detected