~nick-dedekind/unity8/indicator.submenu-reinit

« back to all changes in this revision

Viewing changes to Greeter/GreeterContent.qml

  • Committer: Nick Dedekind
  • Date: 2013-09-16 07:37:30 UTC
  • mfrom: (229.1.91 trunk)
  • Revision ID: nicholas.dedekind@gmail.com-20130916073730-3o9iv6i9h0d2c7rl
merged with trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
 */
16
16
 
17
17
import QtQuick 2.0
 
18
import AccountsService 0.1
18
19
import Ubuntu.Components 0.1
19
20
import LightDM 0.1 as LightDM
20
21
import "../Components"
39
40
        color: "black"
40
41
    }
41
42
 
 
43
    property url backgroundValue: AccountsService.backgroundFile != undefined && AccountsService.backgroundFile.length > 0 ? AccountsService.backgroundFile : shell.defaultBackground
 
44
    onBackgroundValueChanged: wallpaper.source = backgroundValue
 
45
 
42
46
    CrossFadeImage {
43
47
        id: wallpaper
44
 
 
45
 
        source: shell.background
46
48
        anchors.fill: parent
47
49
        fadeInFirst: false
48
50
    }
49
51
 
 
52
    // See Shell.qml's backgroundSettings treatment for why we need a separate
 
53
    // Image, but it boils down to avoiding binding loop detection.
 
54
    Image {
 
55
        source: wallpaper.source
 
56
        height: 0
 
57
        width: 0
 
58
        sourceSize.height: 0
 
59
        sourceSize.width: 0
 
60
        onStatusChanged: {
 
61
            if (status == Image.Error && source != shell.defaultBackground) {
 
62
                wallpaper.source = shell.defaultBackground
 
63
            }
 
64
        }
 
65
    }
 
66
 
50
67
    Rectangle {
51
68
        anchors.fill: parent
52
69
        color: "black"