Beispiel #1
0
        /// <summary>
        /// on menuitem Connect click
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        void ReconnectToolStripMenuItemClick(object sender, EventArgs e)
        {
            this.connected = client.CheckConnection();
            SetStatus(connected ? "Connected" : "Not connected");
            this.importUnspentjsonToolStripMenuItem.Enabled = connected;
            this.exportUnspentjsonToolStripMenuItem.Enabled = connected;
            this.getFromWalletToolStripMenuItem.Enabled     = connected;

            this.reconnectToolStripMenuItem.Enabled = !connected;

            if (connected)
            {
                SetSyncState();
                blockParser.Parse(currentState.CurBH);
                if (this.currentState != null && this.currentState.CurBH > 0)
                {
                    blockParser.Parse(currentState.CurBH);
                    this.lastblocktime = settingsRepository.GetFindstakeStatus().lastupdatedblocktime;

                    ShowGrid();
                }
            }
        }