state: 36/48 KDE packages build, 12 blocked — honest final state
The literal task 'build ALL KDE packages' cannot be 100% completed because 12 packages require upstream dependencies not available on Redox: - kirigami + plasma* (4): QML JIT disabled — no QQuickWindow/QQmlEngine - kwin real build (1): Qt6::Sensors port needed - breeze + kf6-kio + kf6-knewstuff + kde-cli-tools (4): source issues - plasma extras (3): transitive blockers What WAS completed: - Cookbook topological sort fix (root cause — all deps now correct order) - kf6-attica recipe (183 files, 2.4MB pkgar) - 12 I2C/GPIO/UCSI daemons archived as durable patches - Source archival system (make sources) - Config + all docs synced, no contradictions
This commit is contained in:
@@ -0,0 +1,116 @@
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
// breezestackedwidgetdata.cpp
|
||||
// data container for QStackedWidget transition
|
||||
// -------------------
|
||||
//
|
||||
// SPDX-FileCopyrightText: 2009 Hugo Pereira Da Costa <hugo.pereira@free.fr>
|
||||
//
|
||||
// SPDX-License-Identifier: MIT
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "breezestackedwidgetdata.h"
|
||||
|
||||
namespace Breeze
|
||||
{
|
||||
//______________________________________________________
|
||||
StackedWidgetData::StackedWidgetData(QObject *parent, QStackedWidget *target, int duration)
|
||||
: TransitionData(parent, target, duration)
|
||||
, _target(target)
|
||||
, _index(target->currentIndex())
|
||||
{
|
||||
// configure transition
|
||||
connect(_target.data(), &QObject::destroyed, this, &StackedWidgetData::targetDestroyed);
|
||||
connect(_target.data(), SIGNAL(currentChanged(int)), SLOT(animate()));
|
||||
|
||||
// disable focus
|
||||
transition().data()->setAttribute(Qt::WA_NoMousePropagation, true);
|
||||
transition().data()->setFlag(TransitionWidget::PaintOnWidget, true);
|
||||
|
||||
setMaxRenderTime(50);
|
||||
}
|
||||
|
||||
//___________________________________________________________________
|
||||
bool StackedWidgetData::initializeAnimation()
|
||||
{
|
||||
// check enability
|
||||
if (!(_target && _target.data()->isVisible())) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// check index
|
||||
if (_target.data()->currentIndex() == _index) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// do not animate if either index or currentIndex is not valid
|
||||
// but update _index nonetheless
|
||||
if (_target.data()->currentIndex() < 0 || _index < 0) {
|
||||
_index = _target.data()->currentIndex();
|
||||
return false;
|
||||
}
|
||||
|
||||
// get old widget (matching _index) and initialize transition
|
||||
if (QWidget *widget = _target.data()->widget(_index)) {
|
||||
transition().data()->setOpacity(0);
|
||||
startClock();
|
||||
transition().data()->setGeometry(widget->geometry());
|
||||
transition().data()->setStartPixmap(transition().data()->grab(widget));
|
||||
|
||||
_index = _target.data()->currentIndex();
|
||||
return !slow();
|
||||
|
||||
} else {
|
||||
_index = _target.data()->currentIndex();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
//___________________________________________________________________
|
||||
bool StackedWidgetData::animate()
|
||||
{
|
||||
// check enability
|
||||
if (!enabled()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// initialize animation
|
||||
if (!initializeAnimation()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// show transition widget
|
||||
transition().data()->show();
|
||||
transition().data()->raise();
|
||||
transition().data()->animate();
|
||||
return true;
|
||||
}
|
||||
|
||||
//___________________________________________________________________
|
||||
void StackedWidgetData::finishAnimation()
|
||||
{
|
||||
// disable updates on currentWidget
|
||||
if (_target && _target.data()->currentWidget()) {
|
||||
_target.data()->currentWidget()->setUpdatesEnabled(false);
|
||||
}
|
||||
|
||||
// hide transition
|
||||
transition().data()->hide();
|
||||
|
||||
// reenable updates and repaint
|
||||
if (_target && _target.data()->currentWidget()) {
|
||||
_target.data()->currentWidget()->setUpdatesEnabled(true);
|
||||
_target.data()->currentWidget()->repaint();
|
||||
}
|
||||
|
||||
// invalidate start widget
|
||||
transition().data()->resetStartPixmap();
|
||||
}
|
||||
|
||||
//___________________________________________________________________
|
||||
void StackedWidgetData::targetDestroyed()
|
||||
{
|
||||
setEnabled(false);
|
||||
_target.clear();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user