コード例 #1
0
        private void OpenProject(string fileName, bool create, Action <Exception> result)
        {
            EsperProject p = null;

            FileStore.Directory r = null;
            _worker.Do(() =>
            {
                p = new EsperProject(fileName, create);
                r = p.FileStore.GetFullTree();
            },
                       (e) =>
            {
                if (e != null)
                {
                    MessageBox.Show("FileStore error occured:\n" + e.Message ?? e.ToString(),
                                    "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                }
                else
                {
                    BeforeInitialize?.Invoke(this, EventArgs.Empty);
                    _project = p;
                    _root    = r;
                    Init();
                }
                result?.Invoke(e);
            });
        }
コード例 #2
0
        internal void Initialize(Context context)
        {
            BeforeInitialize?.Invoke(this, new EventArgs());

            Bindings.FabricSdk.Fabric.With(new Bindings.FabricSdk.Fabric.Builder(context)
                                           .Kits(Kits.Select(i => i.ToNative()).ToArray())
                                           .Debuggable(Debug)
                                           .Build());

            AfterInitialize?.Invoke(this, new EventArgs());
        }
コード例 #3
0
ファイル: Fabric.cs プロジェクト: wickedw/Fabric.Sdk.Xamarin
        internal void Initialize()
        {
            BeforeInitialize?.Invoke(this, new EventArgs());
            var nativeKits = new List <NSObject>();

            foreach (var kit in Kits)
            {
                nativeKits.Add(kit.ToNative());
            }
            Bindings.FabricSdk.Fabric.With(nativeKits.ToArray());
            AfterInitialize?.Invoke(this, new EventArgs());
        }
コード例 #4
0
ファイル: CefNetApplication.cs プロジェクト: wuzlai521/CefNet
 /// <summary>
 /// Raises the <see cref="BeforeInitialize"/> event.
 /// </summary>
 /// <param name="e">
 /// The <see cref="EventArgs"/> object that contains the event data.
 /// </param>
 protected virtual void OnBeforeInitalize(EventArgs e)
 {
     BeforeInitialize?.Invoke(this, e);
 }
コード例 #5
0
 internal void Initialize()
 {
     BeforeInitialize?.Invoke(this, new EventArgs());
     Bindings.FabricSdk.Fabric.With(Kits.Select(i => i.ToNative()).ToArray());
     AfterInitialize?.Invoke(this, new EventArgs());
 }