Example #1
0
        protected void StatusChanged(object sender, System.EventArgs e)
        {
            Engine.SyncOperationEventArgs soe = (Engine.SyncOperationEventArgs)e;
            switch (soe.SyncOperation)
            {
            default:
                StatusBar.Pop(1);
                StatusBar.Push(1, soe.SyncOperation.ToString() + "...");
                break;

            case Engine.SyncOperation.Failure:
                StatusBar.Pop(1);
                StatusBar.Push(1, "FLAGRANT SYSTEM ERROR!!!");
                Console.WriteLine(Engine.Sync.SyncException.ToString());
                cc.CommandState = CommandStates.FileOpened;
                break;

            case Engine.SyncOperation.Success:
                j.Save();
                StatusBar.Pop(1);
                StatusBar.Push(1, soe.SyncOperation.ToString());
                estore          = new Components.EntriesStore(j);
                tva.Model       = estore;
                cc.CommandState = CommandStates.FileOpened;
                break;
            }
        }
Example #2
0
 private void Sync_SyncOperationCallBack(Engine.SyncOperationEventArgs soe)
 {
     if (MainWindow.Visible)
     {
         Application.Invoke(null, soe, StatusChanged);
     }
 }