[polari] main: Add a main() method



commit ec0a3a74c31a2d7eab49975ecbc7b72900634ed1
Author: Florian Müllner <fmuellner gnome org>
Date:   Sun Feb 22 23:38:03 2015 +0100

    main: Add a main() method
    
    We will start using gjs' package module, so prepare for the move by
    providing the entry method it expects.

 src/main.js |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/src/main.js b/src/main.js
index 73543a8..1081570 100644
--- a/src/main.js
+++ b/src/main.js
@@ -2,8 +2,12 @@ const Application = imports.application;
 const GLib = imports.gi.GLib;
 
 function start() {
+    main(ARGV);
+}
+
+function main(args) {
     let application = new Application.Application();
     if (GLib.getenv('POLARI_PERSIST'))
         application.hold();
-    return application.run(ARGV);
+    return application.run(args);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]