1
0
mirror of https://github.com/KDE/latte-dock.git synced 2025-03-21 22:50:14 +03:00

dont count internalViewSplitters for globalShortcs

-- as mentioned at #879
-- improve also the semantics of globalShortcuts
This commit is contained in:
Michail Vourlakos 2018-02-26 18:12:06 +02:00
parent a6d92153f9
commit db58a24040
3 changed files with 6 additions and 7 deletions

View File

@ -332,8 +332,6 @@ Item {
//! the pseudo index applet after we take into account the separators before it, hidden applets,
//! spacers etc. for example the third applet if there is a separator before it is 1, it isnt 2
function pseudoAppletIndex(realIndex) {
//var pseudoIndex = realIndex;
var counter = 0;
var originalAppletFound = false;
@ -344,7 +342,7 @@ Item {
if (applet.index < realIndex) {
if (applet.isLattePlasmoid) {
counter = counter + root.latteApplet.parabolicManager.countRealTasks;
} else if (!applet.isSeparator && !applet.isSpacer && !applet.isHidden) {
} else if (applet.canShowAppletNumberBadge) {
counter = counter + 1;
}
} else if (applet.index === realIndex) {
@ -362,7 +360,7 @@ Item {
if (applet.index < realIndex) {
if (applet.isLattePlasmoid) {
counter = counter + root.latteApplet.parabolicManager.countRealTasks;
} else if (!applet.isSeparator && !applet.isSpacer && !applet.isHidden) {
} else if (applet.canShowAppletNumberBadge) {
counter = counter + 1;
}
} else if (applet.index === realIndex) {
@ -381,7 +379,7 @@ Item {
if (applet.index < realIndex) {
if (applet.isLattePlasmoid) {
counter = counter + root.latteApplet.parabolicManager.countRealTasks;
} else if (!applet.isSeparator && !applet.isSpacer && !applet.isHidden) {
} else if (applet.canShowAppletNumberBadge) {
counter = counter + 1;
}
} else if (applet.index === realIndex) {

View File

@ -42,6 +42,8 @@ Item {
property bool animationsEnabled: true
property bool animationWasSent: false //protection flag for animation broadcasting
property bool canBeHovered: true
property bool canShowAppletNumberBadge: !isSeparator && !isHidden && !isLattePlasmoid
&& !isSpacer && !isInternalViewSplitter
property bool inFillCalculations: false //temp record, is used in calculations for fillWidth,fillHeight applets
property bool needsFillSpace: { //fill flag, it is used in calculations for fillWidth,fillHeight applets
if (!applet || !applet.Layout || (applet && applet.pluginName === "org.kde.plasma.panelspacer"))

View File

@ -576,8 +576,7 @@ Item{
Component.onCompleted: fixedIndex = parabolicManager.pseudoAppletIndex(index);
property real opacityN: root.showAppletsNumbers && !container.isSeparator && !container.isHidden
&& !container.isLattePlasmoid && !container.isSpacer && fixedIndex<20 ? 1 : 0
property real opacityN: root.showAppletsNumbers && container.canShowAppletNumberBadge && fixedIndex<20 ? 1 : 0
Behavior on opacityN {
NumberAnimation { duration: root.durationTime*2*units.longDuration }