immediate showing tasks in !compositing

--trying to show all tasks in all states directly
when the environment is in !compositing
--block all animations (removals/showings) when
the environment is in !compositing
v0.7
Michail Vourlakos 7 years ago
parent 0835fd7b4d
commit c6cd7d975a

@ -898,7 +898,11 @@ MouseArea{
function activateTask() {
if( mainItemContainer.isLauncher){
wrapper.runLauncherAnimation();
if (Latte.WindowSystem.compositingActive) {
wrapper.runLauncherAnimation();
} else {
launcherAction();
}
}
else{
if (model.IsGroupParent) {
@ -999,8 +1003,10 @@ MouseArea{
function launcherAction(){
// if ((lastButtonClicked == Qt.LeftButton)||(lastButtonClicked == Qt.MidButton)){
inBouncingAnimation = true;
root.addWaitingLauncher(mainItemContainer.launcherUrl);
if (Latte.WindowSystem.compositingActive) {
inBouncingAnimation = true;
root.addWaitingLauncher(mainItemContainer.launcherUrl);
}
tasksModel.requestActivate(modelIndex());
// }
}
@ -1244,7 +1250,9 @@ MouseArea{
|| !launcherIsPresent(mainItemContainer.launcherUrl))
&& mainItemContainer.isStartup);
if ( (isWindow || isStartup) && root.waitingLauncherExists(launcherUrl)) {
if (!Latte.WindowSystem.compositingActive) {
visible = true;
} else if ( (isWindow || isStartup) && root.waitingLauncherExists(launcherUrl)) {
root.waitingLauncherRemoved.connect(slotWaitingLauncherRemoved);
visible = false;
} else if (hideStartup){

@ -22,6 +22,8 @@ import QtQuick 2.0
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.latte 0.1 as Latte
Item{
id: wrapper
@ -311,6 +313,10 @@ Item{
}
Component.onCompleted: {
if (!Latte.WindowSystem.compositingActive) {
opacity = 1;
}
root.updateScale.connect(signalUpdateScale);
}

@ -22,6 +22,8 @@ import QtQuick 2.0
import org.kde.plasma.plasmoid 2.0
import org.kde.latte 0.1 as Latte
SequentialAnimation {
id: taskRealRemovalAnimation
PropertyAction { target: mainItemContainer; property: "ListView.delayRemove"; value: true }
@ -32,10 +34,11 @@ SequentialAnimation {
property bool animation1: ((((tasksModel.launcherPosition(mainItemContainer.launcherUrl) == -1)
&& (tasksModel.launcherPosition(mainItemContainer.launcherUrlWithIcon) == -1) )
|| !launcherIsPresent(mainItemContainer.launcherUrl))
&& !mainItemContainer.isStartup)
&& !mainItemContainer.isStartup && Latte.WindowSystem.compositingActive)
property bool animation4: ((mainItemContainer.launcherUrl===root.launcherForRemoval
|| mainItemContainer.launcherUrlWithIcon===root.launcherForRemoval ) && !mainItemContainer.isStartup)
|| mainItemContainer.launcherUrlWithIcon===root.launcherForRemoval )
&& !mainItemContainer.isStartup && Latte.WindowSystem.compositingActive)
property bool enabledAnimation: (animation1 || animation4) && (root.durationTime !== 0) && !mainItemContainer.inBouncingAnimation;
@ -62,7 +65,8 @@ SequentialAnimation {
root.signalAnimationsNeedLength(1);
if (wrapper.mScale > 1 && !taskRealRemovalAnimation.enabledAnimation && !mainItemContainer.inBouncingAnimation) {
if (wrapper.mScale > 1 && !taskRealRemovalAnimation.enabledAnimation
&& !mainItemContainer.inBouncingAnimation && Latte.WindowSystem.compositingActive) {
parabolicManager.setFrozenTask(mainItemContainer.launcherUrl, wrapper.mScale);
}
}

@ -116,14 +116,18 @@ SequentialAnimation{
var animation2 = ((((tasksModel.launcherPosition(mainItemContainer.launcherUrl) == -1)
&& (tasksModel.launcherPosition(mainItemContainer.launcherUrlWithIcon) == -1) )
|| !launcherIsPresent(mainItemContainer.launcherUrl))
&& mainItemContainer.isWindow);
&& mainItemContainer.isWindow
&& Latte.WindowSystem.compositingActive);
var animation3 = ((!root.taskExists(mainItemContainer.launcherUrl) && mainItemContainer.isLauncher));
var animation3 = (!root.taskExists(mainItemContainer.launcherUrl) && mainItemContainer.isLauncher
&& Latte.WindowSystem.compositingActive);
var activities = tasksModel.launcherActivities(mainItemContainer.launcherUrl);
var animation6 = (root.inActivityChange && mainItemContainer.isWindow
&& activities.indexOf(activityInfo.currentActivity)>=0
&& activities.indexOf(activityInfo.previousActivity) === -1)
&& activities.indexOf(activityInfo.previousActivity) === -1
&& Latte.WindowSystem.compositingActive);
//startup without launcher, animation should be blocked
var hideStartup = ((((tasksModel.launcherPosition(mainItemContainer.launcherUrl) == -1)
@ -131,7 +135,14 @@ SequentialAnimation{
|| !launcherIsPresent(mainItemContainer.launcherUrl))
&& mainItemContainer.isStartup);
if (( animation2 || animation3 || animation6) && (root.durationTime !== 0)){
if (!Latte.WindowSystem.compositingActive) {
mainItemContainer.visible = true;
wrapper.tempScaleWidth = 1;
wrapper.tempScaleHeight = 1;
wrapper.mScale = 1;
wrapper.opacity = 1;
mainItemContainer.inAnimation = false;
} else if (( animation2 || animation3 || animation6) && (root.durationTime !== 0)){
wrapper.tempScaleWidth = 0;
wrapper.tempScaleHeight = 0;
start();

Loading…
Cancel
Save