~mutse-young/ubuntu-docviewer-app/trunk

« back to all changes in this revision

Viewing changes to UnknowTypeDialog.qml

  • Committer: David Planella
  • Date: 2014-10-08 04:45:32 UTC
  • mto: (31.2.8 add-poppler-plugin)
  • mto: This revision was merged to the branch mainline in revision 34.
  • Revision ID: david.planella@ubuntu.com-20141008044532-81w3zoh2j5nmbefu
Reorganized files to prepare inclusion of the file QML plugin into the source tree

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
import QtQuick 2.0
2
 
import Ubuntu.Components 0.1
3
 
import Ubuntu.Components.Popups 0.1
4
 
 
5
 
import "loadComponent.js" as LoadComponent
6
 
 
7
 
Dialog {
8
 
    id: unknownDialog
9
 
    objectName: "unknownDialog"
10
 
    title: i18n.tr("Unknown file type")
11
 
    text: i18n.tr("Sorry but we can't find a way to display this file. Do you want to open it as a plain text?")
12
 
    Button {
13
 
        text: i18n.tr("Yes")
14
 
        color: "green"
15
 
 
16
 
        onClicked: {
17
 
            LoadComponent.load("text/plain");
18
 
            unknownDialog.destroy();
19
 
        }
20
 
    }
21
 
    Button {
22
 
        text: i18n.tr("No")
23
 
        color: "red"
24
 
 
25
 
        onClicked: {
26
 
            unknownDialog.destroy();
27
 
        }
28
 
    }
29
 
}
30