2
import Ubuntu.Components 1.1
7
contentHeight: columnMain.height
8
contentWidth: parent.width
13
objectName: "columnMain"
19
objectName: "textAreaMain"
26
//activeFocusOnPress: true;
31
signal loadCompleted()
33
Component.onCompleted: {
34
var xhr = new XMLHttpRequest;
36
xhr.open("GET", file.path);
37
xhr.onreadystatechange = function() {
38
if (xhr.readyState === XMLHttpRequest.DONE) {
39
textAreaMain.text = xhr.responseText;
40
textAreaMain.loadCompleted();
50
if (event.key === Qt.Key_PageDown) {
51
if (!flickable.atYEnd)
52
flickable.contentY = flickable.contentY + height / 2;
53
event.accepted = true;
54
} else if (event.key === Qt.Key_PageUp) {
55
if (!flickable.atYBeginning)
56
flickable.contentY = flickable.contentY - height / 2;
57
event.accepted = true;
61
flickable.flick( -width / 2, 0)
63
Keys.onRightPressed: {
64
flickable.flick( width / 2, 0)
67
flickable.flick( 0, height / 2)
70
flickable.flick( 0, -height / 2)