Commit 4780bb28 authored by Aleksi Suomalainen's avatar Aleksi Suomalainen Committed by eekkelund

Overlay stuffsies

parent e5c0a690
......@@ -25,9 +25,16 @@ import org.nemomobile.devicelock 1.0
import "compositor"
import "scripts/desktop.js" as Desktop
Item {
id: root
property bool isShaderUsed: false
property bool isAlarmWindow: false
property alias wrapperMystic: mysticWrapper
// Qt::WindowType enum has no option for an Input Method window type. This is a magic value
// used by ubuntumirclient QPA for special clients to request input method windows from Mir.
property int inputMethodWindowType: 2;
Connections {
target: comp.quickWindow
onActiveFocusItemChanged: {
......@@ -267,6 +274,7 @@ Item {
Component {
id: mysticWrapper
WindowWrapperMystic {
id: innerMystic
}
}
Compositor {
......@@ -288,21 +296,12 @@ Item {
var window = null
var wi = null
if (o)
window = o.userData
window = o
if (window == null)
window = homeWindow
setCurrentWindow(window)
if (isAlarmWindow){
comp.topmostAlarmWindow = window
wi = mysticWrapper.createObject(parent, {window: window})
window.userData = wi
setCurrentWindow(wi)
} else {
if (!comp.topmostAlarmWindow) {
wi = mysticWrapper.createObject(parent, {window: window})
}
}
}
function setCurrentWindow(w, skipAnimation) {
......@@ -318,9 +317,7 @@ Item {
topmostApplicationWindow.visible = false
topmostApplicationWindow = topmostWindow
topmostApplicationWindow.visible = true
if (!skipAnimation)
topmostApplicationWindow.animateIn()
w.window.takeFocus()
if (w.window) w.window.takeFocus()
}
}
onSensorOrientationChanged: {
......@@ -332,14 +329,14 @@ Item {
onWindowAdded: {
console.log("Compositor: Window added \"" + window.title + "\""
+ " category: " + window.category)
+ " category: " + window.category + " flags " + window.windowFlags)
var isHomeWindow = window.isInProcess && comp.homeWindow == null
&& window.title === "Home"
var isDialogWindow = window.category === "dialog"
var isNotificationWindow = window.category == "notification"
var isOverlayWindow = window.category == "overlay"
var isAlarmWindow = window.category == "alarm"
var isOverlayWindow = window.category == "overlay" || window.windowFlags === inputMethodWindowType
isAlarmWindow = window.category == "alarm"
var parent = null
if (window.category == "cover" || window.title == "_CoverWindow") {
window.visible = false
......@@ -358,10 +355,12 @@ Item {
}
var w
if (isOverlayWindow)
if (isOverlayWindow) {
console.debug("Have overlay")
w = alphaWrapper.createObject(parent, {
window: window
})
}
else
w = windowWrapper.createObject(parent, {
window: window
......
......@@ -12,16 +12,15 @@ styles.path = /usr/share/lipstick-glacier-home-qt5
styles.files = nemovars.conf
images.path = /usr/share/lipstick-glacier-home-qt5/qml/images
images.files = qml/images/*.png \
qml/images/*.jpg \
qml/images/*.svg
images.files = $$files(qml/images/*.png,false) \
$$files(qml/images/*.jpg,false) \
$$files(qml/images/*.svg,false)
theme.path = /usr/share/lipstick-glacier-home-qt5/qml/theme
theme.files = qml/theme/*.png
theme.files = $$files(qml/theme/*.png,false)
qml.path = /usr/share/lipstick-glacier-home-qt5/qml
qml.files = qml/MainScreen.qml \
qml/compositor.qml \
qml/LauncherItemDelegate.qml \
qml/Lockscreen.qml \
qml/LockscreenClock.qml \
......@@ -30,25 +29,19 @@ qml.files = qml/MainScreen.qml \
qml/ToolBarLayoutExample.qml \
qml/SwitcherItem.qml \
qml/CloseButton.qml \
qml/NotificationPreview.qml \
qml/FeedsPage.qml \
qml/Statusbar.qml \
qml/StatusbarItem.qml \
qml/WifiPanel.qml \
qml/SimPanel.qml \
qml/NumButton.qml \
qml/USBModeSelector.qml \
qml/Pager.qml \
qml/VolumeControl.qml \
qml/BatteryPanel.qml \
qml/CommonPanel.qml \
qml/ShutdownScreen.qml \
qml/GlacierRotation.qml \
qml/DeviceLockUI.qml \
qml/LauncherItemWrapper.qml \
qml/LauncherItemFolder.qml \
qml/SearchListView.qml \
qml/compositor_new.qml
qml/compositor_new.qml \
qml/compositor.qml \
qml/LayerManager.qml
qmlcompositor.path = /usr/share/lipstick-glacier-home-qt5/qml/compositor
qmlcompositor.files = qml/compositor/WindowWrapperMystic.qml \
......@@ -57,8 +50,7 @@ qmlcompositor.files = qml/compositor/WindowWrapperMystic.qml \
qml/compositor/ScreenGestureArea.qml
scripts.path = /usr/share/lipstick-glacier-home-qt5/qml/scripts
scripts.files = qml/scripts/desktop.js \
qml/scripts/rotation.js
scripts.files = qml/scripts/desktop.js
system.path = /usr/share/lipstick-glacier-home-qt5/qml/system
system.files = qml/ShutdownScreen.qml
......@@ -155,4 +147,6 @@ DISTFILES += \
settings-plugins/*/*.qml \
settings-plugins/*/*.json \
settings-plugins/*/*.svg
qml/connectivity/ConnectionSelector.qml \
qml/statusbar/BatteryIndicator.qml \
qml/LayerManager.qml
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment