Пример #1
0
        public Console(string reportPath, BitMobile.Script.ScriptEngine engine)
        {
            _reportPath = reportPath;
            _engine = engine;

            CommandPause = 1000;
        }
Пример #2
0
        public static ScriptEngine LoadScript(System.IO.Stream scriptStream, String name, BitMobile.Debugger.IDebugger debugger)
        {
            if (scripts.ContainsKey(name))
                return scripts[name];
            else
            {
                ScriptEngine engine = new ScriptEngine(name, debugger);
                scripts.Add(name, engine);

                if (scriptStream != null)
                    engine.Run(new System.IO.StreamReader(scriptStream));

                return engine;
            }
        }
Пример #3
0
		public ApplicationContext (NavigationController controller, BitMobile.Application.ApplicationSettings settings, CustomExceptionHandler exceptionHandler)
		{
			GlobalVariables = new Dictionary<string, object> ();

			BitMobile.Application.ApplicationContext.InitContext (this);

			this.Settings = settings;
			this._controller = controller;
			this._exceptionHandler = exceptionHandler;

			LocationProvider = new GPSProvider ();
			LocationTracker = new GPSTracker ();
			GalleryProvider = new GalleryProvider (controller, this);
			CameraProvider = new CameraProvider (controller, this);
			DialogProvider = new DialogProvider (this);
			ClipboardProvider = new ClipboardProvider ();

		}
Пример #4
0
		public ApplicationContext (NavigationController controller, BitMobile.Application.ApplicationSettings settings, CustomExceptionHandler exceptionHandler)
		{
			GlobalVariables = new Dictionary<string, object> ();

			Settings = settings;
			_controller = controller;
			_exceptionHandler = exceptionHandler;

			LocationProvider = new GPSProvider ();
			LocationTracker = new GPSTracker ();
			GalleryProvider = new GalleryProvider (controller, this);
			CameraProvider = new CameraProvider (controller, this);
			DialogProvider = new DialogProvider (this);
			DisplayProvider = new DisplayProvider ();

			var builder = new SolutionBuilder (this);
			builder.Build ();

			StyleSheetContext.Current.Scale = UIScreen.MainScreen.Scale;
		}
Пример #5
0
		public static bool LazyExpression(BitMobile.ValueStack.ValueStack stack, String expression)
		{
			expression = expression.Replace("\"", "").Trim();
			if (expression.StartsWith("$"))
			{
				String[] parts = expression.Split('.');
				if(!parts[0].StartsWith("$"))
					throw new Exception("Invalid expression: " + expression);
				String root = parts[0].Remove(0, 1);
				
				if(stack.Values.ContainsKey(root))
				{
					object obj = stack.Values[root];
					if(obj is BitMobile.Controls.IDataBind)
						return true;
				}
				
			}
			return false;
		}
Пример #6
0
		public override void Invoke(BitMobile.Application.IApplicationContext context)
		{
			base.Invoke(context);
			context.Workflow.InvokeAction(context,name,parameters);
		}
Пример #7
0
 public TemplateView(BitMobile.ValueStack.ValueStack stack, String rootFolder, String name)
 {
     this.stack = stack;
     this.rootFolder = rootFolder;
     this.name = name;
 }
Пример #8
0
		public ScreenData(String name, String controllerName, BitMobile.Controls.IScreen screen)
		{
			this.Name = name;
            this.ControllerName = controllerName;
			this.Screen = screen;
		}
Пример #9
0
 public XmlTemplateView(BitMobile.ValueStack.ValueStack stack, String rootFolder, String name)
     :base(stack, rootFolder, name)
 {
 }
Пример #10
0
 public void RegisterAction(BitMobile.Actions.Action a)
 {
     _currentStep.RegisteredActions.Add(a);
 }
Пример #11
0
 public ScriptEngine(String moduleName, BitMobile.Debugger.IDebugger debugger)
 {
     this.debugger = debugger;
     this.moduleName = moduleName;
     this.SetDebugMode(debugger != null);
 }
Пример #12
0
 public void SetDatabase(BitMobile.DbEngine.IDatabase database)
 {
     sqlManager.SetDatabase(database);
 }
Пример #13
0
 public void Delete(BitMobile.DbEngine.IDbRef obj, bool inTran)
 {
     if (obj != null)
         Database.Current.Delete(obj, inTran);
 }
Пример #14
0
 public void Delete(BitMobile.DbEngine.IDbRef obj)
 {
     if (obj != null)
         Database.Current.Delete(obj, true);
 }