@ -31,11 +31,11 @@ import org.kde.plasma.private.taskmanager 0.1 as TaskManagerApplet
import org . kde . activities 0.1 as Activities
import org . kde . activities 0.1 as Activities
import org . kde . latte 0.2 as Latte
import org . kde . latte . core 0.2 as LatteCore
import org . kde . latte . core 0.2 as LatteCore
import org . kde . latte . components 1.0 as LatteComponents
import org . kde . latte . components 1.0 as LatteComponents
import org . kde . latte . applet . abilities 0.1 as AppletAbility
import org . kde . latte . applet . abilities 0.1 as AppletAbility
import org . kde . latte . private . tasks 0.1 as LatteTasks
import "abilities" as Ability
import "abilities" as Ability
import "previews" as Previews
import "previews" as Previews
@ -160,13 +160,13 @@ Item {
property bool disableRightSpacer: false
property bool disableRightSpacer: false
property bool dockIsHidden: latteView ? latteView.dockIsHidden : false
property bool dockIsHidden: latteView ? latteView.dockIsHidden : false
property bool groupTasksByDefault: plasmoid . configuration . groupTasksByDefault
property bool groupTasksByDefault: plasmoid . configuration . groupTasksByDefault
property bool highlightWindows: latteView ? latteView . hoverAction === Latte . Task s. HighlightWindows || latteView . hoverAction === Latte . Tasks.PreviewAndHighlightWindows :
property bool highlightWindows: latteView ? latteView . hoverAction === Latte Tasks. Type s. HighlightWindows || latteView . hoverAction === Latte Tasks.Type s.PreviewAndHighlightWindows :
plasmoid . configuration . highlightWindows
plasmoid . configuration . highlightWindows
property bool parabolicEffectEnabled: latteView ? latteView.parabolicEffectEnabled : zoomFactor > 1 && ! root . editMode
property bool parabolicEffectEnabled: latteView ? latteView.parabolicEffectEnabled : zoomFactor > 1 && ! root . editMode
property bool scrollingEnabled: plasmoid . configuration . scrollTasksEnabled
property bool scrollingEnabled: plasmoid . configuration . scrollTasksEnabled
property bool autoScrollTasksEnabled: scrollingEnabled && plasmoid . configuration . autoScrollTasksEnabled
property bool autoScrollTasksEnabled: scrollingEnabled && plasmoid . configuration . autoScrollTasksEnabled
property bool manualScrollTasksEnabled: scrollingEnabled && manualScrollTasksType !== Latte . Task s. ManualScrollDisabled
property bool manualScrollTasksEnabled: scrollingEnabled && manualScrollTasksType !== Latte Tasks. Type s. ManualScrollDisabled
property int manualScrollTasksType: plasmoid . configuration . manualScrollTasksType
property int manualScrollTasksType: plasmoid . configuration . manualScrollTasksType
property bool showInfoBadge: plasmoid . configuration . showInfoBadge
property bool showInfoBadge: plasmoid . configuration . showInfoBadge
@ -177,7 +177,7 @@ Item {
property bool showOnlyCurrentScreen: plasmoid . configuration . showOnlyCurrentScreen
property bool showOnlyCurrentScreen: plasmoid . configuration . showOnlyCurrentScreen
property bool showOnlyCurrentDesktop: plasmoid . configuration . showOnlyCurrentDesktop
property bool showOnlyCurrentDesktop: plasmoid . configuration . showOnlyCurrentDesktop
property bool showOnlyCurrentActivity: plasmoid . configuration . showOnlyCurrentActivity
property bool showOnlyCurrentActivity: plasmoid . configuration . showOnlyCurrentActivity
property bool showPreviews: latteView ? latteView . hoverAction === Latte . Task s. PreviewWindows || latteView . hoverAction === Latte . Tasks.PreviewAndHighlightWindows :
property bool showPreviews: latteView ? latteView . hoverAction === Latte Tasks. Type s. PreviewWindows || latteView . hoverAction === Latte Tasks.Type s.PreviewAndHighlightWindows :
plasmoid . configuration . showToolTips
plasmoid . configuration . showToolTips
property bool showWindowActions: plasmoid . configuration . showWindowActions
property bool showWindowActions: plasmoid . configuration . showWindowActions
property bool showWindowsOnlyFromLaunchers: plasmoid . configuration . showWindowsOnlyFromLaunchers
property bool showWindowsOnlyFromLaunchers: plasmoid . configuration . showWindowsOnlyFromLaunchers
@ -198,22 +198,22 @@ Item {
property int modifierClickAction: plasmoid . configuration . modifierClickAction
property int modifierClickAction: plasmoid . configuration . modifierClickAction
property int modifierClick: plasmoid . configuration . modifierClick
property int modifierClick: plasmoid . configuration . modifierClick
property int modifierQt: {
property int modifierQt: {
if ( modifier === Latte . Task s. Shift )
if ( modifier === Latte Tasks. Type s. Shift )
return Qt . ShiftModifier ;
return Qt . ShiftModifier ;
else if ( modifier === Latte . Task s. Ctrl )
else if ( modifier === Latte Tasks. Type s. Ctrl )
return Qt . ControlModifier ;
return Qt . ControlModifier ;
else if ( modifier === Latte . Task s. Alt )
else if ( modifier === Latte Tasks. Type s. Alt )
return Qt . AltModifier ;
return Qt . AltModifier ;
else if ( modifier === Latte . Task s. Meta )
else if ( modifier === Latte Tasks. Type s. Meta )
return Qt . MetaModifier ;
return Qt . MetaModifier ;
else return - 1 ;
else return - 1 ;
}
}
property int taskScrollAction: plasmoid . configuration . taskScrollAction
property int taskScrollAction: plasmoid . configuration . taskScrollAction
onTaskScrollActionChanged: {
onTaskScrollActionChanged: {
if ( taskScrollAction > Latte . Task s. ScrollToggleMinimized ) {
if ( taskScrollAction > Latte Tasks. Type s. ScrollToggleMinimized ) {
/ / ! m i g r a t i n g s c r o l l a c t i o n t o L a t t e .T a s k s . S c r o l l A c t i o n
/ / ! m i g r a t i n g s c r o l l a c t i o n t o L a t t e Ta s k s . T y p e s . S c r o l l A c t i o n
plasmoid . configuration . taskScrollAction = plasmoid . configuration . taskScrollAction - Latte . Task s. ScrollToggleMinimized ;
plasmoid . configuration . taskScrollAction = plasmoid . configuration . taskScrollAction - Latte Tasks. Type s. ScrollToggleMinimized ;
}
}
}
}
@ -314,8 +314,8 @@ Item {
plasmoid . action ( "configure" ) . visible = false ;
plasmoid . action ( "configure" ) . visible = false ;
plasmoid . configuration . isInLatteDock = true ;
plasmoid . configuration . isInLatteDock = true ;
if ( root . launchersGroup === Latte . Task s. LayoutLaunchers
if ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers
|| root . launchersGroup === Latte . Task s. GlobalLaunchers ) {
|| root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) {
tasksModel . updateLaunchersList ( ) ;
tasksModel . updateLaunchersList ( ) ;
}
}
} else {
} else {
@ -406,23 +406,23 @@ Item {
}
}
if ( inConfigureAppletsMode ) {
if ( inConfigureAppletsMode ) {
return Latte . Types . Center ;
return Latte Core . Types . Center ;
} else if ( latteView . panelUserSetAlignment === Latte . Types . Justify ) {
} else if ( latteView . panelUserSetAlignment === Latte Core . Types . Justify ) {
if ( latteView . latteAppletPos >= 0 && latteView . latteAppletPos < 100 ) {
if ( latteView . latteAppletPos >= 0 && latteView . latteAppletPos < 100 ) {
return plasmoid . formFactor === PlasmaCore . Types . Horizontal ? Latte .Types.Left : Latt e. Types . Top ;
return plasmoid . formFactor === PlasmaCore . Types . Horizontal ? Latte Core .Types.Left : Latt eCor e. Types . Top ;
} else if ( latteView . latteAppletPos >= 100 && latteView . latteAppletPos < 200 ) {
} else if ( latteView . latteAppletPos >= 100 && latteView . latteAppletPos < 200 ) {
return Latte . Types . Center ;
return Latte Core . Types . Center ;
} else if ( latteView . latteAppletPos >= 200 ) {
} else if ( latteView . latteAppletPos >= 200 ) {
return plasmoid . formFactor === PlasmaCore . Types . Horizontal ? Latte .Types.Right : Latt e. Types . Bottom ;
return plasmoid . formFactor === PlasmaCore . Types . Horizontal ? Latte Core .Types.Right : Latt eCor e. Types . Bottom ;
}
}
return Latte . Types . Center ;
return Latte Core . Types . Center ;
}
}
return latteView . panelUserSetAlignment ;
return latteView . panelUserSetAlignment ;
}
}
return Latte . Types . Center ;
return Latte Core . Types . Center ;
}
}
}
}
@ -473,12 +473,12 @@ Item {
if ( viewLayout ) {
if ( viewLayout ) {
if ( latteView && latteView . layoutsManager
if ( latteView && latteView . layoutsManager
&& latteView . viewLayout && latteView . universalSettings
&& latteView . viewLayout && latteView . universalSettings
&& ( root . launchersGroup === Latte . Task s. LayoutLaunchers
&& ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers
|| root . launchersGroup === Latte . Task s. GlobalLaunchers ) ) {
|| root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) ) {
if ( root . launchersGroup === Latte . Task s. LayoutLaunchers ) {
if ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers ) {
launchersList = latteView . viewLayout . launchers ;
launchersList = latteView . viewLayout . launchers ;
} else if ( root . launchersGroup === Latte . Task s. GlobalLaunchers ) {
} else if ( root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) {
launchersList = latteView . universalSettings . launchers ;
launchersList = latteView . universalSettings . launchers ;
}
}
}
}
@ -701,12 +701,12 @@ Item {
function updateLaunchersList ( ) {
function updateLaunchersList ( ) {
if ( latteView
if ( latteView
&& ( root . launchersGroup === Latte . Task s. LayoutLaunchers
&& ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers
|| root . launchersGroup === Latte . Task s. GlobalLaunchers ) ) {
|| root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) ) {
if ( root . launchersGroup === Latte . Task s. LayoutLaunchers ) {
if ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers ) {
console . log ( "Tasks: Applying LAYOUT Launchers List..." ) ;
console . log ( "Tasks: Applying LAYOUT Launchers List..." ) ;
tasksModel . launcherList = latteView . viewLayout . launchers ;
tasksModel . launcherList = latteView . viewLayout . launchers ;
} else if ( root . launchersGroup === Latte . Task s. GlobalLaunchers ) {
} else if ( root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) {
console . log ( "Tasks: Applying GLOBAL Launchers List..." ) ;
console . log ( "Tasks: Applying GLOBAL Launchers List..." ) ;
tasksModel . launcherList = latteView . universalSettings . launchers ;
tasksModel . launcherList = latteView . universalSettings . launchers ;
}
}
@ -735,17 +735,17 @@ Item {
if ( viewLayout ) {
if ( viewLayout ) {
if ( latteView && latteView . layoutsManager
if ( latteView && latteView . layoutsManager
&& latteView . viewLayout && latteView . universalSettings
&& latteView . viewLayout && latteView . universalSettings
&& ( root . launchersGroup === Latte . Task s. LayoutLaunchers
&& ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers
|| root . launchersGroup === Latte . Task s. GlobalLaunchers ) ) {
|| root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) ) {
if ( root . launchersGroup === Latte . Task s. LayoutLaunchers ) {
if ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers ) {
latteView . viewLayout . launchers = launcherList ;
latteView . viewLayout . launchers = launcherList ;
} else if ( root . launchersGroup === Latte . Task s. GlobalLaunchers ) {
} else if ( root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) {
latteView . universalSettings . launchers = launcherList ;
latteView . universalSettings . launchers = launcherList ;
}
}
if ( inDraggingPhase ) {
if ( inDraggingPhase ) {
if ( latteView && root . launchersGroup >= Latte . Task s. LayoutLaunchers ) {
if ( latteView && root . launchersGroup >= Latte Core. Type s. LayoutLaunchers ) {
latteView . layoutsManager . launchersSignals . validateLaunchersOrder ( root . viewLayoutName ,
latteView . layoutsManager . launchersSignals . validateLaunchersOrder ( root . viewLayoutName ,
plasmoid . id ,
plasmoid . id ,
root . launchersGroup ,
root . launchersGroup ,
@ -785,12 +785,12 @@ Item {
ActivitiesTools . importLaunchersToNewArchitecture ( ) ;
ActivitiesTools . importLaunchersToNewArchitecture ( ) ;
if ( viewLayout && latteView . universalSettings
if ( viewLayout && latteView . universalSettings
&& ( root . launchersGroup === Latte . Task s. LayoutLaunchers
&& ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers
|| root . launchersGroup === Latte . Task s. GlobalLaunchers ) ) {
|| root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) ) {
if ( root . launchersGroup === Latte . Task s. LayoutLaunchers ) {
if ( root . launchersGroup === Latte Core. Type s. LayoutLaunchers ) {
launcherList = latteView . viewLayout . launchers ;
launcherList = latteView . viewLayout . launchers ;
} else if ( root . launchersGroup === Latte . Task s. GlobalLaunchers ) {
} else if ( root . launchersGroup === Latte Core. Type s. GlobalLaunchers ) {
launcherList = latteView . universalSettings . launchers ;
launcherList = latteView . universalSettings . launchers ;
}
}
} else {
} else {
@ -1209,7 +1209,7 @@ Item {
onUrlsDropped: {
onUrlsDropped: {
/ / ! i n f o r m s y n c e d d o c k s f o r n e w d r o p p e d l a u n c h e r s
/ / ! i n f o r m s y n c e d d o c k s f o r n e w d r o p p e d l a u n c h e r s
if ( latteView && root . launchersGroup >= Latte . Task s. LayoutLaunchers && onlyLaunchersInList ( urls ) ) {
if ( latteView && root . launchersGroup >= Latte Core. Type s. LayoutLaunchers && onlyLaunchersInList ( urls ) ) {
latteView . layoutsManager . launchersSignals . urlsDropped ( root . viewLayoutName ,
latteView . layoutsManager . launchersSignals . urlsDropped ( root . viewLayoutName ,
root . launchersGroup , urls ) ;
root . launchersGroup , urls ) ;
return ;
return ;
@ -1567,7 +1567,7 @@ Item {
if ( separatorName !== "" ) {
if ( separatorName !== "" ) {
tasksExtendedManager . addLauncherToBeMoved ( separatorName , Math . max ( 0 , pos ) ) ;
tasksExtendedManager . addLauncherToBeMoved ( separatorName , Math . max ( 0 , pos ) ) ;
if ( latteView && root . launchersGroup >= Latte . Task s. LayoutLaunchers ) {
if ( latteView && root . launchersGroup >= Latte Core. Type s. LayoutLaunchers ) {
latteView . layoutsManager . launchersSignals . addLauncher ( root . viewLayoutName ,
latteView . layoutsManager . launchersSignals . addLauncher ( root . viewLayoutName ,
root . launchersGroup , separatorName ) ;
root . launchersGroup , separatorName ) ;
} else {
} else {
@ -1740,7 +1740,7 @@ Item {
if ( separatorName !== "" ) {
if ( separatorName !== "" ) {
tasksExtendedManager . addLauncherToBeMoved ( separatorName , Math . max ( 0 , pos ) ) ;
tasksExtendedManager . addLauncherToBeMoved ( separatorName , Math . max ( 0 , pos ) ) ;
if ( latteView && root . launchersGroup >= Latte . Task s. LayoutLaunchers ) {
if ( latteView && root . launchersGroup >= Latte Core. Type s. LayoutLaunchers ) {
latteView . layoutsManager . launchersSignals . addLauncher ( root . launchersGroup , separatorName ) ;
latteView . layoutsManager . launchersSignals . addLauncher ( root . launchersGroup , separatorName ) ;
} else {
} else {
tasksModel . requestAddLauncher ( separatorName ) ;
tasksModel . requestAddLauncher ( separatorName ) ;
@ -1752,7 +1752,7 @@ Item {
var separatorName = parabolicManager . lastPresentSeparatorName ( ) ;
var separatorName = parabolicManager . lastPresentSeparatorName ( ) ;
if ( separatorName !== "" ) {
if ( separatorName !== "" ) {
if ( latteView && root . launchersGroup >= Latte . Task s. LayoutLaunchers ) {
if ( latteView && root . launchersGroup >= Latte Core. Type s. LayoutLaunchers ) {
latteView . layoutsManager . launchersSignals . removeLauncher ( root . viewLayoutName ,
latteView . layoutsManager . launchersSignals . removeLauncher ( root . viewLayoutName ,
root . launchersGroup , separatorName ) ;
root . launchersGroup , separatorName ) ;
} else {
} else {
@ -1941,7 +1941,7 @@ Item {
/ / / B o t t o m E d g e
/ / / B o t t o m E d g e
State {
State {
name: "bottomCenter"
name: "bottomCenter"
when: ( root . location === PlasmaCore . Types . BottomEdge && root . alignment === Latte . Types . Center )
when: ( root . location === PlasmaCore . Types . BottomEdge && root . alignment === Latte Core . Types . Center )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -1954,7 +1954,7 @@ Item {
} ,
} ,
State {
State {
name: "bottomLeft"
name: "bottomLeft"
when: ( root . location === PlasmaCore . Types . BottomEdge && root . alignment === Latte . Types . Left )
when: ( root . location === PlasmaCore . Types . BottomEdge && root . alignment === Latte Core . Types . Left )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -1967,7 +1967,7 @@ Item {
} ,
} ,
State {
State {
name: "bottomRight"
name: "bottomRight"
when: ( root . location === PlasmaCore . Types . BottomEdge && root . alignment === Latte . Types . Right )
when: ( root . location === PlasmaCore . Types . BottomEdge && root . alignment === Latte Core . Types . Right )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -1981,7 +1981,7 @@ Item {
/ / / T o p E d g e
/ / / T o p E d g e
State {
State {
name: "topCenter"
name: "topCenter"
when: ( root . location === PlasmaCore . Types . TopEdge && root . alignment === Latte . Types . Center )
when: ( root . location === PlasmaCore . Types . TopEdge && root . alignment === Latte Core . Types . Center )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -1994,7 +1994,7 @@ Item {
} ,
} ,
State {
State {
name: "topLeft"
name: "topLeft"
when: ( root . location === PlasmaCore . Types . TopEdge && root . alignment === Latte . Types . Left )
when: ( root . location === PlasmaCore . Types . TopEdge && root . alignment === Latte Core . Types . Left )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2007,7 +2007,7 @@ Item {
} ,
} ,
State {
State {
name: "topRight"
name: "topRight"
when: ( root . location === PlasmaCore . Types . TopEdge && root . alignment === Latte . Types . Right )
when: ( root . location === PlasmaCore . Types . TopEdge && root . alignment === Latte Core . Types . Right )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2021,7 +2021,7 @@ Item {
/ / / / L e f t E d g e
/ / / / L e f t E d g e
State {
State {
name: "leftCenter"
name: "leftCenter"
when: ( root . location === PlasmaCore . Types . LeftEdge && root . alignment === Latte . Types . Center )
when: ( root . location === PlasmaCore . Types . LeftEdge && root . alignment === Latte Core . Types . Center )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2034,7 +2034,7 @@ Item {
} ,
} ,
State {
State {
name: "leftTop"
name: "leftTop"
when: ( root . location === PlasmaCore . Types . LeftEdge && root . alignment === Latte . Types . Top )
when: ( root . location === PlasmaCore . Types . LeftEdge && root . alignment === Latte Core . Types . Top )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2047,7 +2047,7 @@ Item {
} ,
} ,
State {
State {
name: "leftBottom"
name: "leftBottom"
when: ( root . location === PlasmaCore . Types . LeftEdge && root . alignment === Latte . Types . Bottom )
when: ( root . location === PlasmaCore . Types . LeftEdge && root . alignment === Latte Core . Types . Bottom )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2061,7 +2061,7 @@ Item {
/ / / R i g h t E d g e
/ / / R i g h t E d g e
State {
State {
name: "rightCenter"
name: "rightCenter"
when: ( root . location === PlasmaCore . Types . RightEdge && root . alignment === Latte . Types . Center )
when: ( root . location === PlasmaCore . Types . RightEdge && root . alignment === Latte Core . Types . Center )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2074,7 +2074,7 @@ Item {
} ,
} ,
State {
State {
name: "rightTop"
name: "rightTop"
when: ( root . location === PlasmaCore . Types . RightEdge && root . alignment === Latte . Types . Top )
when: ( root . location === PlasmaCore . Types . RightEdge && root . alignment === Latte Core . Types . Top )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine
@ -2087,7 +2087,7 @@ Item {
} ,
} ,
State {
State {
name: "rightBottom"
name: "rightBottom"
when: ( root . location === PlasmaCore . Types . RightEdge && root . alignment === Latte . Types . Bottom )
when: ( root . location === PlasmaCore . Types . RightEdge && root . alignment === Latte Core . Types . Bottom )
AnchorChanges {
AnchorChanges {
target: barLine
target: barLine