Exemplo n.º 1
0
        public void Init(MoSync.Core core, Stream resources)
        {
            mCore    = core;
            mRuntime = new MoSync.Runtime(mCore);
            mCore.SetRuntime(mRuntime);

            if (resources != null)
            {
                if (!mRuntime.LoadResources(resources))
                {
                    MoSync.Util.CriticalError("Failed to load resources!");
                }
            }

            mCore.Init();
            mRuntime.Init();
        }
Exemplo n.º 2
0
        public void Init(MoSync.Core core, Stream resources)
        {
            mCore = core;
            mRuntime = new MoSync.Runtime(mCore);
            mCore.SetRuntime(mRuntime);

            if (resources != null)
            {
                if (!mRuntime.LoadResources(resources))
                {
                    MoSync.Util.CriticalError("Failed to load resources!");
                }
            }

            mCore.Init();
            mRuntime.Init();
        }
Exemplo n.º 3
0
        private void LoadProgram(Stream s)
        {
            Core core = new MoSync.CoreInterpreted(s);

            mCore    = core;
            mRuntime = new MoSync.Runtime(mCore);
            mCore.SetRuntime(mRuntime);

            mCore.Init();   // moves s.Position
            if (s.Position == s.Length)
            {
                s = null;
            }
            if (s != null)
            {
                if (!mRuntime.LoadResources(s))
                {
                    MoSync.Util.CriticalError("Failed to load resources!");
                }
            }

            mRuntime.Init();
        }
Exemplo n.º 4
0
        private void LoadProgram(Stream s)
        {
            Core core = new MoSync.CoreInterpreted(s);
            mCore = core;
            mRuntime = new MoSync.Runtime(mCore);
            mCore.SetRuntime(mRuntime);

            mCore.Init();   // moves s.Position
            if (s.Position == s.Length)
                s = null;
            if (s != null)
            {
                if (!mRuntime.LoadResources(s))
                {
                    MoSync.Util.CriticalError("Failed to load resources!");
                }
            }

            mRuntime.Init();
        }