// Decompiled with JetBrains decompiler
// Type: FileCash_v3._0.NotifyWindow
// Assembly: FileCash_v3.0, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: 1DECC99D-34C5-4E02-A85D-DC744B5C555A
// Assembly location: C:\Users\Administrateur\Downloads\Virusshare-00001-msil\Constructor.MSIL.ArchSMS.a-33cc8dceb24ed9df287e1f92d02773477af42b8d2b6de53a45bb9b5a3ead070b.exe

using FileCash_v3._0.Properties;
using System;
using System.ComponentModel;
using System.Drawing;
using System.Threading;
using System.Windows.Forms;

namespace FileCash_v3._0
{
  public class NotifyWindow : Form
  {
    private IContainer components;
    private Label label1;
    private Panel panel1;
    private Label label5;
    private Label label4;
    private Label label3;
    private Label label2;
    private PictureBox pictureBox1;
    private Label Sum;
    private Label Rebils;
    private Label Subs;
    private Label Payd;
    private Label Opened;
    private BackgroundWorker backgroundWorker1;
    private Rectangle rScreen = Screen.GetWorkingArea(Screen.PrimaryScreen.Bounds);
    protected bool closePressed;
    protected bool textPressed;
    protected bool titlePressed;
    protected bool closeHot;
    protected bool textHot;
    protected bool titleHot;
    protected System.Windows.Forms.Timer viewClock;
    public NotifyWindow.ClockStates ClockState;
    private TimerResoultParam TimerParam;

    protected override void Dispose(bool disposing)
    {
      if (disposing && this.components != null)
        this.components.Dispose();
      base.Dispose(disposing);
    }

    private void InitializeComponent()
    {
      this.label1 = new Label();
      this.panel1 = new Panel();
      this.Sum = new Label();
      this.Rebils = new Label();
      this.Subs = new Label();
      this.Payd = new Label();
      this.Opened = new Label();
      this.label5 = new Label();
      this.label4 = new Label();
      this.label3 = new Label();
      this.label2 = new Label();
      this.pictureBox1 = new PictureBox();
      this.backgroundWorker1 = new BackgroundWorker();
      this.panel1.SuspendLayout();
      ((ISupportInitialize) this.pictureBox1).BeginInit();
      this.SuspendLayout();
      this.label1.AutoSize = true;
      this.label1.BackColor = Color.Transparent;
      this.label1.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.label1.ForeColor = Color.White;
      this.label1.Location = new Point(3, 20);
      this.label1.Name = "label1";
      this.label1.Size = new Size(124, 14);
      this.label1.TabIndex = 1;
      this.label1.Text = "Открытий: ................... ";
      this.panel1.BackColor = Color.Transparent;
      this.panel1.BackgroundImage = (Image) Resources.bg_popup;
      this.panel1.Controls.Add((Control) this.Sum);
      this.panel1.Controls.Add((Control) this.Rebils);
      this.panel1.Controls.Add((Control) this.Subs);
      this.panel1.Controls.Add((Control) this.Payd);
      this.panel1.Controls.Add((Control) this.Opened);
      this.panel1.Controls.Add((Control) this.label5);
      this.panel1.Controls.Add((Control) this.label4);
      this.panel1.Controls.Add((Control) this.label3);
      this.panel1.Controls.Add((Control) this.label2);
      this.panel1.Controls.Add((Control) this.pictureBox1);
      this.panel1.Controls.Add((Control) this.label1);
      this.panel1.Cursor = Cursors.Default;
      this.panel1.Location = new Point(0, 0);
      this.panel1.Name = "panel1";
      this.panel1.Size = new Size(200, 120);
      this.panel1.TabIndex = 2;
      this.Sum.AutoSize = true;
      this.Sum.BackColor = Color.Transparent;
      this.Sum.Font = new Font("Arial", 11f, FontStyle.Bold, GraphicsUnit.Pixel, (byte) 204);
      this.Sum.ForeColor = Color.White;
      this.Sum.Location = new Point(45, 97);
      this.Sum.Margin = new Padding(0);
      this.Sum.Name = "Sum";
      this.Sum.Size = new Size(32, 14);
      this.Sum.TabIndex = 11;
      this.Sum.Text = "Sum";
      this.Rebils.AutoSize = true;
      this.Rebils.BackColor = Color.Transparent;
      this.Rebils.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.Rebils.ForeColor = Color.White;
      this.Rebils.Location = new Point(124, 73);
      this.Rebils.Name = "Rebils";
      this.Rebils.Size = new Size(36, 14);
      this.Rebils.TabIndex = 10;
      this.Rebils.Text = "Rebils";
      this.Subs.AutoSize = true;
      this.Subs.BackColor = Color.Transparent;
      this.Subs.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.Subs.ForeColor = Color.White;
      this.Subs.Location = new Point(124, 58);
      this.Subs.Name = "Subs";
      this.Subs.Size = new Size(32, 14);
      this.Subs.TabIndex = 9;
      this.Subs.Text = "Subs";
      this.Payd.AutoSize = true;
      this.Payd.BackColor = Color.Transparent;
      this.Payd.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.Payd.ForeColor = Color.White;
      this.Payd.Location = new Point(124, 34);
      this.Payd.Name = "Payd";
      this.Payd.Size = new Size(31, 14);
      this.Payd.TabIndex = 8;
      this.Payd.Text = "Payd";
      this.Opened.AutoSize = true;
      this.Opened.BackColor = Color.Transparent;
      this.Opened.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.Opened.ForeColor = Color.White;
      this.Opened.Location = new Point(124, 20);
      this.Opened.Name = "Opened";
      this.Opened.Size = new Size(45, 14);
      this.Opened.TabIndex = 7;
      this.Opened.Text = "Opened";
      this.label5.AutoSize = true;
      this.label5.BackColor = Color.Transparent;
      this.label5.Font = new Font("Arial", 11f, FontStyle.Bold, GraphicsUnit.Pixel, (byte) 204);
      this.label5.ForeColor = Color.White;
      this.label5.Location = new Point(3, 97);
      this.label5.Name = "label5";
      this.label5.Size = new Size(41, 14);
      this.label5.TabIndex = 6;
      this.label5.Text = "Итого:";
      this.label4.AutoSize = true;
      this.label4.BackColor = Color.Transparent;
      this.label4.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.label4.ForeColor = Color.White;
      this.label4.Location = new Point(3, 73);
      this.label4.Name = "label4";
      this.label4.Size = new Size(125, 14);
      this.label4.TabIndex = 5;
      this.label4.Text = "Ребилов: ...................... ";
      this.label3.AutoSize = true;
      this.label3.BackColor = Color.Transparent;
      this.label3.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.label3.ForeColor = Color.White;
      this.label3.Location = new Point(3, 58);
      this.label3.Name = "label3";
      this.label3.Size = new Size(125, 14);
      this.label3.TabIndex = 4;
      this.label3.Text = "Подписок / Отписок: ... ";
      this.label2.AutoSize = true;
      this.label2.BackColor = Color.Transparent;
      this.label2.Font = new Font("Arial", 11f, FontStyle.Regular, GraphicsUnit.Pixel, (byte) 204);
      this.label2.ForeColor = Color.White;
      this.label2.Location = new Point(3, 34);
      this.label2.Name = "label2";
      this.label2.Size = new Size(124, 14);
      this.label2.TabIndex = 3;
      this.label2.Text = "Оплат(распаковок): ... ";
      this.pictureBox1.Cursor = Cursors.Hand;
      this.pictureBox1.Image = (Image) Resources.closebut;
      this.pictureBox1.Location = new Point(177, 3);
      this.pictureBox1.Name = "pictureBox1";
      this.pictureBox1.Size = new Size(20, 20);
      this.pictureBox1.SizeMode = PictureBoxSizeMode.AutoSize;
      this.pictureBox1.TabIndex = 2;
      this.pictureBox1.TabStop = false;
      this.pictureBox1.Click += new EventHandler(this.pictureBox1_Click);
      this.backgroundWorker1.WorkerReportsProgress = true;
      this.backgroundWorker1.DoWork += new DoWorkEventHandler(this.backgroundWorker1_DoWork);
      this.backgroundWorker1.ProgressChanged += new ProgressChangedEventHandler(this.backgroundWorker1_ProgressChanged);
      this.backgroundWorker1.RunWorkerCompleted += new RunWorkerCompletedEventHandler(this.backgroundWorker1_RunWorkerCompleted);
      this.AutoScaleDimensions = new SizeF(6f, 13f);
      this.AutoScaleMode = AutoScaleMode.Font;
      this.ClientSize = new Size(200, 120);
      this.Controls.Add((Control) this.panel1);
      this.FormBorderStyle = FormBorderStyle.None;
      this.Name = nameof (NotifyWindow);
      this.ShowIcon = false;
      this.ShowInTaskbar = false;
      this.StartPosition = FormStartPosition.Manual;
      this.Text = nameof (NotifyWindow);
      this.Load += new EventHandler(this.NotifyWindow_Load);
      this.panel1.ResumeLayout(false);
      this.panel1.PerformLayout();
      ((ISupportInitialize) this.pictureBox1).EndInit();
      this.ResumeLayout(false);
    }

    public NotifyWindow(ref TimerResoultParam Tmparam)
    {
      this.TimerParam = Tmparam;
      this.InitializeComponent();
      this.Opened.Text = this.TimerParam.copencount;
      this.Payd.Text = this.TimerParam.cunpackcount + " / " + this.TimerParam.cunpacksum + " руб.";
      this.Subs.Text = this.TimerParam.csubs + " / " + this.TimerParam.coffsubs;
      this.Rebils.Text = this.TimerParam.cmtrebils + " / " + this.TimerParam.cmtrebilsSum + " руб.";
      int num = Convert.ToInt32(this.TimerParam.balance) - Convert.ToInt32(this.TimerParam.oldbalance);
      if (num >= 0)
        this.Sum.Text = " + " + (object) num + " руб.";
      this.Location = new Point(this.rScreen.Width - this.Width - 2, this.rScreen.Height - this.Height - 1);
    }

    private void pictureBox1_Click(object sender, EventArgs e) => this.Close();

    private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e) => Thread.Sleep(5000);

    private void backgroundWorker1_ProgressChanged(object sender, ProgressChangedEventArgs e)
    {
    }

    private void backgroundWorker1_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) => this.Close();

    private void NotifyWindow_Load(object sender, EventArgs e) => this.backgroundWorker1.RunWorkerAsync();

    public enum ClockStates
    {
      Opening,
      Closing,
      Showing,
      None,
    }
  }
}
