예제 #1
0
 private void btnInit_Click(object sender, EventArgs e)
 {
     plShowLog.BringToFront();
     LKCLI.Init();
     LKCLI.InitEthermint();
     LKCLI.InitTendermint();
     ihslib.FileHandle.FileHelper.CreateFile(GlobalVar.lock_file);
     LogMessage("迅雷链初始化完成,正在启动,请稍后......");
     btnStart.PerformClick();
     //NewBlockInfos.GetBlockByNumber(200000);
 }
예제 #2
0
        private async void timerUpdateBlockInfo_TickAsync(object sender, EventArgs e)
        {
            if (!LKCLI.IsRunning())
            {
                return;
            }
            if (!Methods.Common.RPCServerTest())
            {
                return;
            }
            var newBlockNum = await GlobalVar.web3_local.GetBlockNumberAsync();

            lbBlockHeight.Text = newBlockNum;
            lbMainHeight.Text  = await GlobalVar.web3_main.GetBlockNumberAsync();

            webNewBlock.DocumentText = await NewBlockInfos.GetNewBlockHtmlAsync(newBlockNum);

            //lbOnlineNode.Text = await GlobalVar.local_web3.GetPeerCountAsync();
        }
예제 #3
0
 private void btnRestart_Click(object sender, EventArgs e)
 {
     LKCLI.Restart();
     LogMessage("迅雷链数据节点重启完成,开始同步数据......");
 }
예제 #4
0
 private void btnStop_Click(object sender, EventArgs e)
 {
     LKCLI.Stop();
     LogMessage("迅雷链数据节点已停止运行......");
 }
예제 #5
0
 private void btnStart_Click(object sender, EventArgs e)
 {
     LKCLI.Start();
     LogMessage("迅雷链数据节点启动成功,开始同步数据......");
 }
예제 #6
0
 private static void Application_ApplicationExit(object sender, EventArgs e)
 {
     LKCLI.Stop();
     Environment.Exit(0);
 }