3 @author: Sudheer K. <scifi1947 at gmail.com>
4 @license: GNU General Public License
8 import com.nokia.meego 1.0
9 import "file:///usr/lib/qt4/imports/com/meego/UIConstants.js" as UIConstants
10 //import "file:///usr/lib/qt4/imports/com/nokia/extras/constants.js" as ExtrasConstants
11 import "Library/js/DBUtility.js" as DBUtility
12 import "Library/js/CoreLogic.js" as Core
18 Component.onCompleted: {
19 DBUtility.initialize();
29 anchors.top:parent.top
30 width: parent.width ; height: appWindow.inPortrait ? UIConstants.HEADER_DEFAULT_HEIGHT_PORTRAIT: UIConstants.HEADER_DEFAULT_HEIGHT_LANDSCAPE
35 font.family: UIConstants.FONT_FAMILY
36 font.pixelSize: UIConstants.FONT_SLARGE
37 color: UIConstants.COLOR_FOREGROUND
38 anchors.centerIn: parent
39 horizontalAlignment: Text.AlignHCenter;
40 text: qsTr("VICaR - Rules")
47 anchors {top: headerRect.bottom; bottom: parent.bottom}
73 height: UIConstants.LIST_ITEM_HEIGHT_DEFAULT
77 visible: mouseArea.pressed
78 source: theme.inverted ?
79 'image://theme/meegotouch-list-fullwidth-inverted-background-pressed-vertical-center':
80 'image://theme/meegotouch-list-fullwidth-background-pressed-vertical-center'
84 height: parent.height;
85 anchors {left: parent.left;leftMargin: UIConstants.DEFAULT_MARGIN; right: parent.right; rightMargin: UIConstants.DEFAULT_MARGIN}
86 font.family: UIConstants.FONT_FAMILY
87 font.pixelSize: UIConstants.FONT_SLARGE
88 color: UIConstants.COLOR_FOREGROUND
89 horizontalAlignment: Text.AlignLeft; verticalAlignment: Text.AlignVCenter
90 wrapMode: Text.WordWrap
91 //lineHeightMode: Text.ProportionalHeight; lineHeight: 1.5
92 text: "For numbers starting with "+numberpattern+ ", use "+gatewaynumber;
98 ruleContextMenu.ruleID = id;
99 console.log("Setting Rule ID as "+id);
100 ruleContextMenu.open();
108 property int ruleID:0
114 Core.editRule(ruleContextMenu.ruleID);
118 text: qsTr("Delete");
120 DBUtility.removeRule(ruleContextMenu.ruleID);
132 anchors.centerIn: parent
133 text: qsTr("Add rules for call routing.")