138 lines
4.7 KiB
C#
138 lines
4.7 KiB
C#
// Decompiled with JetBrains decompiler
|
|||
|
|
// Type: Raton.Forms.ClientForms.Audio.ratonVolume
|
||
|
|
// Assembly: Raton, Version=0.4.0.0, Culture=neutral, PublicKeyToken=null
|
||
|
|
// MVID: 36C4E416-7F8D-4D23-930F-B5CCB0D810E7
|
||
|
|
// Assembly location: C:\Users\user\Desktop\v3.8.0 Deluxe Plugins (v4.0.0) cracked\Raton.exe
|
||
|
|
|
||
|
|
using DarkModeForms;
|
||
|
|
using Raton.Classes;
|
||
|
|
using Server.Connection;
|
||
|
|
using Stuff;
|
||
|
|
using System;
|
||
|
|
using System.ComponentModel;
|
||
|
|
using System.Drawing;
|
||
|
|
using System.Windows.Forms;
|
||
|
|
|
||
|
|
#nullable disable
|
||
|
|
namespace Raton.Forms.ClientForms.Audio;
|
||
|
|
|
||
|
|
public class ratonVolume : Form
|
||
|
|
{
|
||
|
|
private int scrolling;
|
||
|
|
private IContainer components;
|
||
|
|
private TrackBar trackBar1;
|
||
|
|
private Label label1;
|
||
|
|
private Label label2;
|
||
|
|
private Timer timer1;
|
||
|
|
private Label label3;
|
||
|
|
private Timer timer2;
|
||
|
|
|
||
|
|
public SillyClient SillyClient { get; set; }
|
||
|
|
|
||
|
|
public ratonVolume()
|
||
|
|
{
|
||
|
|
this.InitializeComponent();
|
||
|
|
DarkMode.Start((Form) this);
|
||
|
|
}
|
||
|
|
|
||
|
|
private void ratonVolume_Load(object sender, EventArgs e) => this.timer1.Start();
|
||
|
|
|
||
|
|
private void timer1_Tick(object sender, EventArgs e)
|
||
|
|
{
|
||
|
|
if (this.SillyClient != null && this.SillyClient.isConnected())
|
||
|
|
return;
|
||
|
|
this.Close();
|
||
|
|
}
|
||
|
|
|
||
|
|
private void trackBar1_Scroll(object sender, EventArgs e)
|
||
|
|
{
|
||
|
|
++this.scrolling;
|
||
|
|
this.timer2.Stop();
|
||
|
|
this.timer2.Start();
|
||
|
|
}
|
||
|
|
|
||
|
|
private void timer2_Tick(object sender, EventArgs e)
|
||
|
|
{
|
||
|
|
if (this.scrolling > 999)
|
||
|
|
{
|
||
|
|
this.Close();
|
||
|
|
int num = (int) Messenger.MessageBox("Scroll overload, chill!");
|
||
|
|
}
|
||
|
|
this.timer2.Stop();
|
||
|
|
Pack pack = new Pack();
|
||
|
|
pack.SetString("Packet", "Volume");
|
||
|
|
pack.SetInt("Volume", this.trackBar1.Value);
|
||
|
|
this.SillyClient.Send(pack.Pacc());
|
||
|
|
this.label3.Text = this.trackBar1.Value.ToString();
|
||
|
|
}
|
||
|
|
|
||
|
|
protected override void Dispose(bool disposing)
|
||
|
|
{
|
||
|
|
if (disposing && this.components != null)
|
||
|
|
this.components.Dispose();
|
||
|
|
base.Dispose(disposing);
|
||
|
|
}
|
||
|
|
|
||
|
|
private void InitializeComponent()
|
||
|
|
{
|
||
|
|
this.components = (IContainer) new System.ComponentModel.Container();
|
||
|
|
ComponentResourceManager componentResourceManager = new ComponentResourceManager(typeof (ratonVolume));
|
||
|
|
this.trackBar1 = new TrackBar();
|
||
|
|
this.label1 = new Label();
|
||
|
|
this.label2 = new Label();
|
||
|
|
this.timer1 = new Timer(this.components);
|
||
|
|
this.label3 = new Label();
|
||
|
|
this.timer2 = new Timer(this.components);
|
||
|
|
this.trackBar1.BeginInit();
|
||
|
|
this.SuspendLayout();
|
||
|
|
this.trackBar1.Location = new Point(12, 53);
|
||
|
|
this.trackBar1.Maximum = 100;
|
||
|
|
this.trackBar1.Name = "trackBar1";
|
||
|
|
this.trackBar1.Size = new Size(380, 45);
|
||
|
|
this.trackBar1.TabIndex = 0;
|
||
|
|
this.trackBar1.Value = 50;
|
||
|
|
this.trackBar1.Scroll += new EventHandler(this.trackBar1_Scroll);
|
||
|
|
this.label1.AutoSize = true;
|
||
|
|
this.label1.Font = new Font("Microsoft JhengHei", 9f, FontStyle.Bold, GraphicsUnit.Point, (byte) 0);
|
||
|
|
this.label1.Location = new Point(12, 9);
|
||
|
|
this.label1.Name = "label1";
|
||
|
|
this.label1.Size = new Size(124, 16 /*0x10*/);
|
||
|
|
this.label1.TabIndex = 1;
|
||
|
|
this.label1.Text = "Change the volume";
|
||
|
|
this.label2.AutoSize = true;
|
||
|
|
this.label2.Font = new Font("Microsoft JhengHei", 9f, FontStyle.Regular, GraphicsUnit.Point, (byte) 0);
|
||
|
|
this.label2.Location = new Point(12, 25);
|
||
|
|
this.label2.Name = "label2";
|
||
|
|
this.label2.Size = new Size(196, 16 /*0x10*/);
|
||
|
|
this.label2.TabIndex = 2;
|
||
|
|
this.label2.Text = "Scroll and the volume will change";
|
||
|
|
this.timer1.Tick += new EventHandler(this.timer1_Tick);
|
||
|
|
this.label3.Font = new Font("Microsoft JhengHei", 9f, FontStyle.Regular, GraphicsUnit.Point, (byte) 0);
|
||
|
|
this.label3.Location = new Point(347, 34);
|
||
|
|
this.label3.Name = "label3";
|
||
|
|
this.label3.Size = new Size(45, 16 /*0x10*/);
|
||
|
|
this.label3.TabIndex = 3;
|
||
|
|
this.label3.Text = "50";
|
||
|
|
this.label3.TextAlign = ContentAlignment.MiddleRight;
|
||
|
|
this.timer2.Interval = 500;
|
||
|
|
this.timer2.Tick += new EventHandler(this.timer2_Tick);
|
||
|
|
this.AutoScaleDimensions = new SizeF(6f, 13f);
|
||
|
|
this.AutoScaleMode = AutoScaleMode.Font;
|
||
|
|
this.ClientSize = new Size(408, 109);
|
||
|
|
this.Controls.Add((Control) this.label2);
|
||
|
|
this.Controls.Add((Control) this.trackBar1);
|
||
|
|
this.Controls.Add((Control) this.label1);
|
||
|
|
this.Controls.Add((Control) this.label3);
|
||
|
|
this.FormBorderStyle = FormBorderStyle.FixedSingle;
|
||
|
|
this.Icon = (Icon) componentResourceManager.GetObject("$this.Icon");
|
||
|
|
this.MaximizeBox = false;
|
||
|
|
this.Name = nameof (ratonVolume);
|
||
|
|
this.StartPosition = FormStartPosition.CenterScreen;
|
||
|
|
this.Text = nameof (ratonVolume);
|
||
|
|
this.Load += new EventHandler(this.ratonVolume_Load);
|
||
|
|
this.trackBar1.EndInit();
|
||
|
|
this.ResumeLayout(false);
|
||
|
|
this.PerformLayout();
|
||
|
|
}
|
||
|
|
}
|