webglade

JavaScript library to dynamically create XUL GUI from Glade XML files
git clone https://logand.com/git/webglade.git/
Log | Files | Refs | README | LICENSE

hw.js (407B)


      1 function main() {
      2   loadXml
      3   ('hw.glade',
      4    function (glade) {
      5      var widgets = parseGlade(glade);
      6      wbuild(document.documentElement, [ widgets['window1'] ]);
      7    });
      8 };
      9 
     10 WHANDLER['hw'] =
     11 function (e) {
     12   alert('Hello world! ' + e + ' ' + e.target);
     13 };
     14 
     15 WHANDLER['delete_event'] =
     16 function () {
     17   alert('delete_event');
     18 };
     19 
     20 WHANDLER['destroy'] =
     21 function () {
     22   alert('destroy');
     23   gtkMainQuit();
     24 };
     25