Skip to content

Commit

Permalink
Bug fixes
Browse files Browse the repository at this point in the history
Fixed incorrect label in Account page, updated volume slider
  • Loading branch information
Codrax committed Jun 14, 2023
1 parent 578216f commit ceacce6
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 45 deletions.
58 changes: 29 additions & 29 deletions MainUI.dfm
Original file line number Diff line number Diff line change
Expand Up @@ -194947,13 +194947,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down Expand Up @@ -194988,13 +194988,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down Expand Up @@ -195029,13 +195029,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = True
State = cbChecked
end
Expand Down Expand Up @@ -196664,8 +196664,8 @@ object UIForm: TUIForm
Font.Style = []
ParentFont = False
Layout = tlCenter
ExplicitLeft = 52
ExplicitTop = -2
ExplicitLeft = 62
ExplicitTop = -6
end
object Data_Artists: TLabel
Left = 265
Expand Down Expand Up @@ -199985,13 +199985,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = True
State = cbChecked
end
Expand Down Expand Up @@ -206140,13 +206140,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = True
State = cbChecked
end
Expand Down Expand Up @@ -206750,13 +206750,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = True
State = cbChecked
end
Expand Down Expand Up @@ -206830,9 +206830,9 @@ object UIForm: TUIForm
ParentBackground = True
AccentColor = acAccentAdjust
Presets = cslNone
Foreground.Enter = 6914986
Foreground.Leave = 5270161
Foreground.Down = 3625336
Foreground.Enter = 6525346
Foreground.Leave = 4880521
Foreground.Down = 3235696
Foreground.Border = clGray
Foreground.BorderThick = 0
Foreground.MultiColor = False
Expand Down Expand Up @@ -206893,13 +206893,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = True
State = cbChecked
end
Expand Down Expand Up @@ -206933,13 +206933,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down Expand Up @@ -207034,13 +207034,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down Expand Up @@ -207135,13 +207135,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down Expand Up @@ -207174,13 +207174,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down Expand Up @@ -207213,13 +207213,13 @@ object UIForm: TUIForm
Colors.Leave = 16250866
Colors.Enter = 15658729
Colors.Down = 15066593
Colors.Checked = 5270161
Colors.Checked = 4880521
Colors.CheckIndicator = clWhite
Colors.TransparentCenter = True
ColorsBorder.Leave = 9013638
ColorsBorder.Enter = 9013638
ColorsBorder.Down = 12434873
ColorsBorder.Checked = 5270161
ColorsBorder.Checked = 4880521
Checked = False
State = cbUnchecked
end
Expand Down
26 changes: 19 additions & 7 deletions MainUI.pas
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ interface
Cod.Audio, UITypes, Types, Math, Performance,
Cod.Math, System.IniFiles, System.Generics.Collections, Web.HTTPApp,
Bass, System.Win.TaskbarCore, Vcl.Taskbar, Cod.Visual.CheckBox,
Vcl.ControlList, Cod.StringUtils, Vcl.OleCtrls, SHDocVw, Vcl.Menus;
Vcl.ControlList, Cod.StringUtils, Vcl.OleCtrls, SHDocVw, Vcl.Menus,
Cod.MasterVolume;

type
// Cardinals
Expand Down Expand Up @@ -667,8 +668,8 @@ TUIForm = class(TForm)
const
// SYSTEM
V_MAJOR = 1;
V_MINOR = 4;
V_PATCH = 9;
V_MINOR = 5;
V_PATCH = 0;

UPDATE_URL = 'http://vinfo.codrutsoftware.cf/version_iBroadcast';
DOWNLOAD_UPDATE_URL = 'https://github.com/Codrax/iBroadcast-For-Windows/releases/';
Expand Down Expand Up @@ -816,7 +817,7 @@ TUIForm = class(TForm)
RepeatMode: TRepeat = TRepeat.All;

// Server
ArtworkID: integer = 0;
ArtworkID: integer = 1;

// Queue Popup
QueueAnProgress: integer;
Expand Down Expand Up @@ -1301,7 +1302,12 @@ procedure TUIForm.Button_VolumeMouseUp(Sender: TObject; Button: TMouseButton;
VolumePop.Top := Button_Volume.ClientToScreen(Point(0, 0)).Y - VolumePop.Height;
VolumePop.Left := Button_Volume.ClientToScreen(Point(0, 0)).X - VolumePop.Width + Button_Volume.Width;

VolumePop.CSlider1.Position := trunc(Player.Volume * 1000);
try
VolumePop.CSlider1.Position := trunc(GetMasterVolume * 1000);
except
VolumePop.CSlider1.Position := trunc(Player.Volume * 1000);
end;


VolumePop.Show;
end;
Expand Down Expand Up @@ -4688,7 +4694,7 @@ procedure TUIForm.ReloadLibrary;
Complete_Email.Caption := Format(CAPTION_EMAIL, [MaskEmailAdress(Account.EmailAdress)]);
Complete_Email.Hint := Format(CAPTION_EMAIL, [Account.EmailAdress]);

Complete_User.Caption := Format(CAPTION_EMAIL, [datetostr(Account.CreationDate)]);
Complete_User.Caption := Format(CAPTION_USER, [datetostr(Account.CreationDate)]);

if Account.Verified then
Complete_Verify.Caption := Format(CAPTION_VERIFIED, [datetostr(Account.VerificationDate)])
Expand Down Expand Up @@ -5255,6 +5261,7 @@ procedure TUIForm.StartCheckForUpdate;
procedure TUIForm.StatusChanged;
var
I: Integer;
VolPosition: integer;
begin
AddToLog('Status changed! Form.StatusChanged');

Expand All @@ -5267,7 +5274,12 @@ procedure TUIForm.StatusChanged;
TickUpdate;

// Volume
case ceil(Player.Volume * 4) of
try
VolPosition := ceil(GetMasterVolume * 4);
except
VolPosition := ceil(Player.Volume * 4);
end;
case VolPosition of
0: Button_Volume.BSegoeIcon := #$E74F;
1: Button_Volume.BSegoeIcon := #$E992;
2: Button_Volume.BSegoeIcon := #$E993;
Expand Down
3 changes: 0 additions & 3 deletions VolumePopup.dfm
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,8 @@ object VolumePop: TVolumePop
Font.Height = -16
Font.Name = 'Segoe UI'
Font.Style = []
OldCreateOrder = False
Position = poDesigned
OnDeactivate = FormDeactivate
PixelsPerInch = 96
TextHeight = 21
object Label1: TLabel
AlignWithMargins = True
Expand Down Expand Up @@ -71,6 +69,5 @@ object VolumePop: TVolumePop
Max = 1000
Min = 0
Position = 50
ExplicitTop = 30
end
end
9 changes: 7 additions & 2 deletions VolumePopup.pas
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ interface

uses
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Cod.Visual.Slider, Vcl.StdCtrls, BASS;
Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Cod.Visual.Slider, Vcl.StdCtrls, BASS,
Cod.MasterVolume;

type
TVolumePop = class(TForm)
Expand All @@ -30,7 +31,11 @@ implementation

procedure TVolumePop.CSlider1Change(Sender: CSlider; Position, Max, Min: Integer);
begin
BASS_SetVolume( Position / 1000 );
try
SetMasterVolume( Position / 1000 );
except
//BASS_SetVolume( Position / 1000 );
end;

UIForm.StatusChanged;
end;
Expand Down
8 changes: 4 additions & 4 deletions iBroadcast.dproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<Base>True</Base>
<Config Condition="'$(Config)'==''">Release</Config>
<Platform Condition="'$(Platform)'==''">Win64</Platform>
<TargetedPlatforms>3</TargetedPlatforms>
<TargetedPlatforms>2</TargetedPlatforms>
<AppType>Application</AppType>
<MainSource>iBroadcast.dpr</MainSource>
</PropertyGroup>
Expand Down Expand Up @@ -95,8 +95,8 @@
<Manifest_File>$(BDS)\bin\default_app.manifest</Manifest_File>
<Icon_MainIcon>iBroadcast_Icon.ico</Icon_MainIcon>
<AppDPIAwarenessMode>none</AppDPIAwarenessMode>
<VerInfo_Keys>CompanyName=Codrut Software;FileDescription=Codrut&apos;s iBroadcast for Windows;FileVersion=1.4.0.0;InternalName=;LegalCopyright=Codrut Software;LegalTrademarks=Petculescu Codrut;OriginalFilename=;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
<VerInfo_MinorVer>4</VerInfo_MinorVer>
<VerInfo_Keys>CompanyName=Codrut Software;FileDescription=Codrut&apos;s iBroadcast for Windows;FileVersion=1.5.0.0;InternalName=;LegalCopyright=Codrut Software;LegalTrademarks=Petculescu Codrut;OriginalFilename=;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
<VerInfo_MinorVer>5</VerInfo_MinorVer>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1)'!=''">
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
Expand Down Expand Up @@ -1100,7 +1100,7 @@
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
</Deployment>
<Platforms>
<Platform value="Win32">True</Platform>
<Platform value="Win32">False</Platform>
<Platform value="Win64">True</Platform>
</Platforms>
</BorlandProject>
Expand Down
Binary file modified iBroadcast.res
Binary file not shown.

0 comments on commit ceacce6

Please sign in to comment.