Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
lunarcon committed Apr 11, 2020
1 parent 607fc0b commit af80a1c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 29 deletions.
9 changes: 0 additions & 9 deletions DelV/DelV.vbproj
Original file line number Diff line number Diff line change
Expand Up @@ -93,15 +93,6 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.CSharp" />
<Reference Include="Microsoft.Toolkit.Forms.UI.Controls, Version=6.0.0.0, Culture=neutral, PublicKeyToken=4aff67a105548ee2, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Toolkit.Forms.UI.Controls.6.0.0\lib\net462\Microsoft.Toolkit.Forms.UI.Controls.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Toolkit.Forms.UI.XamlHost, Version=6.0.0.0, Culture=neutral, PublicKeyToken=4aff67a105548ee2, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Toolkit.Forms.UI.XamlHost.6.0.0\lib\net462\Microsoft.Toolkit.Forms.UI.XamlHost.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Toolkit.Win32.UI.XamlHost.Managed, Version=6.0.0.0, Culture=neutral, PublicKeyToken=4aff67a105548ee2, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Toolkit.UI.XamlHost.6.0.0\lib\net462\Microsoft.Toolkit.Win32.UI.XamlHost.Managed.dll</HintPath>
</Reference>
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="System" />
Expand Down
44 changes: 24 additions & 20 deletions DelV/taskbar.vb
Original file line number Diff line number Diff line change
Expand Up @@ -28,27 +28,31 @@ Public Class taskbar
Catch

End Try
Dim FODLERID_AppsFolder = New Guid("{9E3995AB-1F9C-4F13-B827-48B24B6C7174}")
Try
Dim FODLERID_AppsFolder = New Guid("{9E3995AB-1F9C-4F13-B827-48B24B6C7174}")
Dim appsFolder As ShellObject = CType(KnownFolderHelper.FromKnownFolderId(FODLERID_AppsFolder), ShellObject)
Dim pinned = CType(appsFolder.ParsingName, String) + "\TaskBar\"
For Each file As String In Directory.GetFiles(pinned)
If file.Contains(".lnk") Then
Dim btx As New taskbar_button
Dim appicon = AddIcon(file, 1)
btx.Tag = file
btx.BackColor = Color.Transparent
'btx.Button1.FlatStyle = FlatStyle.Flat
btx.Button1.BackColor = Color.FromArgb(5, 0, 0, 0)
btx.Size = New Size(50, 42)
btx.Name = Path.GetFileNameWithoutExtension(file)
btx.Dock = DockStyle.Left
btx.Menu.Items.Item(1).Visible = False
btx.Menu.Items.Item(3).Visible = False
Rescale(0.45, appicon, btx)
btx.Margin = New Padding(10, 0, 0, 0)
pnned_panel.Controls.Add(btx)
End If
Next
Dim pinned = CType(appsFolder.ParsingName, String) + "\TaskBar\"
For Each file As String In Directory.GetFiles(pinned)
If file.Contains(".lnk") Then
Dim btx As New taskbar_button
Dim appicon = AddIcon(file, 1)
btx.Tag = file
btx.BackColor = Color.Transparent
'btx.Button1.FlatStyle = FlatStyle.Flat
btx.Button1.BackColor = Color.FromArgb(5, 0, 0, 0)
btx.Size = New Size(50, 42)
btx.Name = Path.GetFileNameWithoutExtension(file)
btx.Dock = DockStyle.Left
btx.Menu.Items.Item(1).Visible = False
btx.Menu.Items.Item(3).Visible = False
Rescale(0.45, appicon, btx)
btx.Margin = New Padding(10, 0, 0, 0)
pnned_panel.Controls.Add(btx)
End If
Next
Catch
MsgBox("Could not get pinned apps!")
End Try
End Sub
Protected Overrides ReadOnly Property CreateParams As CreateParams
Get
Expand Down

0 comments on commit af80a1c

Please sign in to comment.