~ubuntu-branches/ubuntu/wily/unity-2d/wily

« back to all changes in this revision

Viewing changes to places/TickBox.qml

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2011-08-25 18:16:57 UTC
  • mfrom: (1.1.19 upstream)
  • Revision ID: james.westby@ubuntu.com-20110825181657-opb29rqsxae3i98f
Tags: 4.2.0-0ubuntu1
* New upstream release:
  - [panel] application menus do not appear on first hover after dismissal
    (lp: #825262)
  - [dash] Lens icons badly scaled (lp: #825368)
  - [panel] indicators are shifted offscreen to the right (lp: #827673)
  - [panel] scrubbing from system indicators to menubar should be possible
    (lp: #706903)
  - [launcher] Closed applications don't get their launcher counts cleared
    (lp: #767367)
  - [dash] selected item should not be underlined but use the same 
    treatment as unity (lp: #817456)
  - [dash] categories should be collapsed by default (lp: #827214)
  - [dash] Ratings filter (lp: #831855)
  - [dash] Multirange filter (lp: #831856)
  - [dash] ToggleButton filter (lp: #831857)
  - [dash] Icon size must be bigger to match the mockups (lp: #831858)
  - [dash] "Refine search" right margin should be 15 pixels (lp: #832058)
  - [dash] "Refine search" should be "Filter results" (lp: #832060)
  - [dash] Font sizes should match new design (lp: #832114)
  - [panel] Glitch: application menu appearing when pressing the BFB 
    (lp: #825060)
  - [panel] Glitch: application menus are quickly opened after a drag gesture
    (lp: #825267)
  - [dash] File thumbnails aspect ratio is not respected (lp: #832204)
* debian/control: require current the current versions of nux and unity

Show diffs side-by-side

added added

removed removed

Lines of Context:
42
42
 
43
43
    Rectangle {
44
44
        id: container
45
 
        width: parent.width //should be 144
46
 
        height: parent.height //should be 29
47
 
        border.color: "white"
48
 
        border.width: 1
49
 
        color: ( checked ) ? "white" : "#00000000"
50
 
        opacity: if (checked) return 0.8
51
 
                 else if (parent.state == "selected") return 1
52
 
                 else return 0.5
 
45
 
 
46
        /* FIXME: Rectangle's borders grow half inside and half outside of the
 
47
           rectangle. In order to avoid it being clipped, we adjust its size
 
48
           and position depending on its border's width.
 
49
 
 
50
           Ref.: http://lists.qt.nokia.com/pipermail/qt-qml/2010-May/000264.html
 
51
        */
 
52
        x: Math.floor(border.width / 2)
 
53
        y: Math.floor(border.width / 2)
 
54
        width: parent.width - border.width
 
55
        height: parent.height - border.width
 
56
        border.color: if ( parent.state == "selected") return "white"
 
57
                      else if ( checked ) return "#cdffffff" // 13% opaque
 
58
                      else return "#21ffffff" // 80% opaque
 
59
        border.width: ( checked ) ? 2 : 1
 
60
        color: ( checked ) ? "#21ffffff" : "transparent"
53
61
        radius: 5
54
62
    }
55
63
 
56
64
    TextCustom {
57
65
        id: label
58
 
        anchors.fill: container
 
66
        anchors.fill: parent
59
67
        width: parent.width
60
68
        horizontalAlignment: Text.AlignHCenter
61
69
        verticalAlignment: Text.AlignVCenter
62
 
        font.pixelSize: 15
63
 
        color: ( checked ) ? "black" : "white"
 
70
        fontSize: "medium"
 
71
        color: "white"
64
72
        text: tickBox.text
65
73
        elide: Text.ElideRight
66
74
        opacity: ( !canUncheck ) ? 0 : 1