src/Builder4/DialogPluginWebkit.bjs
[app.Builder.js] / src / Builder4 / DialogPluginWebkit.bjs
1 {
2  "name" : "DialogPluginWebkit",
3  "parent" : "",
4  "title" : "",
5  "path" : "/home/alan/gitlive/app.Builder.js/src/Builder4/DialogPluginWebkit.bjs",
6  "permname" : "",
7  "modOrder" : "",
8  "items" : [
9   {
10    "xtype" : "Dialog",
11    "$ xns" : "Gtk",
12    "items" : [
13     {
14      "xtype" : "VBox",
15      "$ pack" : "get_content_area().add",
16      "$ xns" : "Gtk",
17      "items" : [
18       {
19        "* init" : "function() {\n    XObject.prototype.init.call(this);\n      this.el.set_policy (Gtk.PolicyType.AUTOMATIC, Gtk.PolicyType.AUTOMATIC)\n}\n",
20        "* pack" : "pack_end,true,true,0",
21        "xtype" : "ScrolledWindow",
22        "$ xns" : "Gtk",
23        "items" : [
24         {
25          "$ clear" : "function() {\n    \n    \n    \n     \n   // remove..\n    var s  = \"document.body.textContent='';\"\n        \n    this.el.execute_script(s);\n        \n        \n    \n    \n    \n}\n",
26          "id" : "patchview",
27          "xtype" : "WebView",
28          "* pack" : "add",
29          "$ showDiff" : "function(files) {\n    this.clear();\n    \n    \n     var model = this.get('/historyTreeStore');\n    \n    if (model.release === false) {\n        return;\n    }\n    \n    var diff = Merger.repo.diff(files, model.release, model.rev);\n    \n   // remove..\n    var s  = \"var pre  = document.createElement('pre'); document.body.appendChild(pre);\";\n    s += \"pre.textContent =  \" +\n             JSON.stringify(Merger.repo.lastCmd + \"\\n\") + '+  ' + \n           JSON.stringify(diff) + \";\";\n    print(s);\n        \n    this.el.execute_script(s);\n        \n        \n    \n    \n    \n}\n",
30          "$ xns" : "WebKit"
31         }
32        ]
33       }
34      ]
35     }
36    ]
37   }
38  ]
39 }