Skip to content

Commit 6acb947

Browse files
committed
little code clean up.
1 parent b43fb1c commit 6acb947

File tree

1 file changed

+2
-35
lines changed

1 file changed

+2
-35
lines changed

src/umain.pas

Lines changed: 2 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,6 @@ TfrmMain = class(TForm)
195195
procedure LoadSiblings(const FName: string; FList: TStringList);
196196
{$ifdef windows}
197197
procedure EnableBlur;
198-
//procedure AeroGlass;
199198
{$endif}
200199
public
201200
property FileList: TStringList read FstFileList;
@@ -1220,7 +1219,6 @@ procedure TfrmMain.TimerEffectStartTimer(Sender: TObject);
12201219
end;
12211220

12221221
procedure TfrmMain.TimerDelayStartTimer(Sender: TObject);
1223-
12241222
begin
12251223
// needs to this delay to work around some issue for inFrame start.
12261224
if self.AlphaBlendValue < 255 then
@@ -2265,7 +2263,7 @@ procedure TfrmMain.PopupMenuMainPopup(Sender: TObject);
22652263
MenuItemSlideshowInFrame.Caption:=resstrInFrameView ;
22662264
MenuItemSlideshow.Caption:=resstrFullscreenView;
22672265

2268-
MenuItemNext.enabled:=false; //visible or enabled:=false;
2266+
MenuItemNext.enabled:=false;
22692267
MenuItemBack.enabled:=false;
22702268
end;
22712269

@@ -2553,11 +2551,7 @@ procedure TfrmMain.EnableBlur;
25532551
begin
25542552
accent.AccentState := ACCENT_ENABLE_BLURBEHIND;
25552553
//accent.AccentState := ACCENT_ENABLE_ACRYLICBLURBEHIND;
2556-
2557-
//accent.GradientColor := (100 SHL 24) or ($FFE3E0DE);
2558-
//accent.GradientColor := (100 SHL 24) or ($000000FF);
2559-
//accent.GradientColor := (100 SHL 24) or ($11880000);
2560-
2554+
accent.GradientColor := (100 SHL 24) or ($FFE3E0DE);
25612555
accent.AccentFlags := DrawLeftBorder or DrawTopBorder or DrawRightBorder or DrawBottomBorder;
25622556

25632557
data.Attribute := WCA_ACCENT_POLICY;
@@ -2575,33 +2569,6 @@ procedure TfrmMain.EnableBlur;
25752569
end;
25762570

25772571
end;
2578-
(*
2579-
procedure TfrmMain.AeroGlass;
2580-
var
2581-
Aero: BOOL;
2582-
Area: TRect;
2583-
hDWM: THandle;
2584-
begin
2585-
hDWM:=LoadLibrary('dwmapi.dll');
2586-
try
2587-
@DwmIsCompositionEnabled:=GetProcAddress(hDWM,'DwmIsCompositionEnabled');
2588-
if @DwmIsCompositionEnabled<>nil then
2589-
DwmIsCompositionEnabled(Aero);
2590-
if Aero then
2591-
begin
2592-
Area:=Rect(-1,-1,-1,-1);
2593-
Color:=clBlack;
2594-
@DwmExtendFrameIntoClientArea:=GetProcAddress(hDWM,'DwmExtendFrameIntoClientArea');
2595-
if @DwmExtendFrameIntoClientArea<>nil then
2596-
DwmExtendFrameIntoClientArea(Handle,@Area);
2597-
2598-
end
2599-
else ShowMessage('Aero is Disabled');
2600-
finally
2601-
FreeLibrary(hDWM);
2602-
end;
2603-
end;
2604-
*)
26052572

26062573
initialization
26072574
SetWindowCompositionAttribute := GetProcAddress(GetModuleHandle(user32), 'SetWindowCompositionAttribute');

0 commit comments

Comments
 (0)