Skip to content

Commit

Permalink
2.0.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
stax76 committed May 22, 2019
1 parent 57337ff commit 4a904a2
Show file tree
Hide file tree
Showing 22 changed files with 54 additions and 1,994 deletions.
Binary file added Black.ico
Binary file not shown.
Binary file removed ClassicIcon.ico
Binary file not shown.
4 changes: 2 additions & 2 deletions Forms/HelpForm.vb
Expand Up @@ -43,7 +43,7 @@ Public Class HelpForm

Sub New()
InitializeComponent()
Icon = My.Resources.Icons.ModernIcon
Icon = g.Icon
End Sub

Sub New(path As String)
Expand All @@ -55,7 +55,7 @@ Public Class HelpForm
MsgWarn("Failed to load: " + path)
End Try

Icon = My.Resources.Icons.ModernIcon
Icon = g.Icon
End Sub

Private DocumentValue As HelpDocument
Expand Down
12 changes: 11 additions & 1 deletion Forms/MainForm.vb
Expand Up @@ -1079,7 +1079,7 @@ Public Class MainForm
g.MainForm = Me
LoadSettings()
MenuItemEx.UseTooltips = s.EnableTooltips
Icon = My.Resources.Icons.ModernIcon
Icon = g.Icon
InitializeComponent()

ScaleClientSize(41, 26.5)
Expand Down Expand Up @@ -3305,6 +3305,15 @@ Public Class MainForm

ui.CreateFlowPage("User Interface", True)

ui.AddLabel("Icon File:")

Dim tb = ui.AddTextButton
tb.Label.Visible = False
tb.BrowseFile("ico|*.ico", Folder.Startup + "Apps\Icons")
tb.Edit.Expand = True
tb.Edit.Text = s.IconFile
tb.Edit.SaveAction = Sub(value) s.IconFile = value

Dim t = ui.AddText()
t.Text = "Remember Window Positions:"
t.Help = "Title or beginning of the title of windows of which the location should be remembered. For all windows enter '''all'''."
Expand Down Expand Up @@ -3388,6 +3397,7 @@ Public Class MainForm
SetMenuStyle()
s.UpdateRecentProjects(Nothing)
UpdateRecentProjectsMenu()
If Not Icon Is g.Icon Then Icon = g.Icon
g.SaveSettings()
End If

Expand Down
2 changes: 1 addition & 1 deletion Forms/MediaInfoFolderViewForm.vb
Expand Up @@ -62,7 +62,7 @@ Public Class MediaInfoFolderViewForm
MyBase.New()
InitializeComponent()

Icon = My.Resources.Icons.ModernIcon
Icon = g.Icon

lv.View = View.Details
lv.FullRowSelect = True
Expand Down
2 changes: 1 addition & 1 deletion Forms/PreviewForm.vb
Expand Up @@ -295,7 +295,7 @@ Public Class PreviewForm
Sub New(aviSynthDocument As VideoScript)
MyBase.New()
InitializeComponent()
Icon = My.Resources.Icons.ModernIcon
Icon = g.Icon

CommandManager.AddCommandsFromObject(Me)
CommandManager.AddCommandsFromObject(g.DefaultCommands)
Expand Down
4 changes: 2 additions & 2 deletions Forms/ProcForm.vb
Expand Up @@ -222,8 +222,8 @@ Public Class ProcForm
InitializeComponent()
AddHandler Application.ThreadException, AddressOf g.OnUnhandledException
mbShutdown.Add(System.Enum.GetValues(GetType(ShutdownMode)).Cast(Of Object))
Icon = My.Resources.Icons.ModernIcon
NotifyIcon.Icon = My.Resources.Icons.ModernIcon
Icon = g.Icon
NotifyIcon.Icon = g.Icon
NotifyIcon.Text = "StaxRip"
TaskbarButtonCreatedMessage = Native.RegisterWindowMessage("TaskbarButtonCreated")
ScaleClientSize(42, 28)
Expand Down
2 changes: 2 additions & 0 deletions General/ApplicationSettings.vb
Expand Up @@ -61,6 +61,7 @@ Public Class ApplicationSettings
Public WriteDebugLog As Boolean
Public ThumbnailBackgroundColor As Color = Color.AliceBlue
Public MinPreviewSize As Integer = 60
Public IconFile As String

Property WasUpdated As Boolean Implements ISafeSerialization.WasUpdated

Expand Down Expand Up @@ -272,6 +273,7 @@ Public Class ApplicationSettings
End If

If LastSourceDir = "" Then LastSourceDir = ""
If IconFile = "" OrElse Not File.Exists(IconFile) Then IconFile = Folder.Startup + "Apps\Icons\Black.ico"

Migrate()
End Sub
Expand Down
4 changes: 2 additions & 2 deletions General/Extensions.vb
Expand Up @@ -705,7 +705,7 @@ Module UIExtensions
End Sub

<Extension()>
Sub SetInitDir(d As System.Windows.Forms.FileDialog, ParamArray paths As String())
Sub SetInitDir(d As FileDialog, ParamArray paths As String())
For Each i In paths
If Not Directory.Exists(i) Then i = i.ExistingParent

Expand All @@ -717,7 +717,7 @@ Module UIExtensions
End Sub

<Extension()>
Sub SetFilter(d As System.Windows.Forms.FileDialog, values As IEnumerable(Of String))
Sub SetFilter(d As FileDialog, values As IEnumerable(Of String))
d.Filter = FileTypes.GetFilter(values)
End Sub

Expand Down
22 changes: 22 additions & 0 deletions General/GlobalClass.vb
Expand Up @@ -887,6 +887,28 @@ Public Class GlobalClass
OnException(DirectCast(e.ExceptionObject, Exception))
End Sub

Private IconValue As Icon
Private LastIconFile As String

Public Property Icon As Icon
Get
If IconValue Is Nothing OrElse s.IconFile <> LastIconFile Then
Dim iconFile = s.IconFile
If Not File.Exists(iconFile) Then iconFile = Folder.Startup + "Apps\Icons\Black.ico"

If File.Exists(iconFile) Then
IconValue = New Icon(iconFile)
LastIconFile = iconFile
End If
End If

Return IconValue
End Get
Set(ByVal value As Icon)
IconValue = value
End Set
End Property

Sub MakeBugReport(e As Exception)
If e Is Nothing AndAlso Not g.IsValidSource(False) Then Exit Sub

Expand Down
Binary file removed ModernIcon.ico
Binary file not shown.
Binary file removed ModernIcon.png
Binary file not shown.
4 changes: 2 additions & 2 deletions My Project/AssemblyInfo.vb
Expand Up @@ -7,5 +7,5 @@ Imports System.Runtime.InteropServices
<Assembly: AssemblyCopyright("2002-2019 StaxRip authors")>
<Assembly: ComVisible(False)>
<Assembly: Guid("54d5dc0f-6ba7-42f0-a82f-9c71d561cb8b")>
<Assembly: AssemblyVersion("2.0.2.0")>
<Assembly: AssemblyFileVersion("2.0.2.0")>
<Assembly: AssemblyVersion("2.0.2.1")>
<Assembly: AssemblyFileVersion("2.0.2.1")>
87 changes: 0 additions & 87 deletions My Project/Icons.Designer.vb

This file was deleted.

127 changes: 0 additions & 127 deletions My Project/Icons.resx

This file was deleted.

0 comments on commit 4a904a2

Please sign in to comment.