Skip to content

Commit

Permalink
v19 release changes: Improved the FAH Web Control page button behavio…
Browse files Browse the repository at this point in the history
…r. Improved toggling the Tools panel. Upgraded to CefSharp/Chrome v69.

Created CureCoin Wallet v2.0.0.1 installer with the CureCoin Blockchain for easier install for new and upgrading users.
Updated CureCoin POS info: 4 day maturity (for v2.0) for staking, instead of 30 day (for v1.9.x.x).
CureCoin Wallet: Include a 'peers.dat' file for more bootstrap nodes with the CureCoin installer.
  • Loading branch information
Hou5e committed Dec 24, 2018
1 parent a5d2b16 commit 54f5ab3
Show file tree
Hide file tree
Showing 8 changed files with 88 additions and 62 deletions.
24 changes: 12 additions & 12 deletions Browser/FoldingBrowser.vbproj
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.props" Condition="Exists('packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.props')" />
<Import Project="packages\CefSharp.Common.67.0.0\build\CefSharp.Common.props" Condition="Exists('packages\CefSharp.Common.67.0.0\build\CefSharp.Common.props')" />
<Import Project="packages\cef.redist.x86.3.3396.1786\build\cef.redist.x86.props" Condition="Exists('packages\cef.redist.x86.3.3396.1786\build\cef.redist.x86.props')" />
<Import Project="packages\cef.redist.x64.3.3396.1786\build\cef.redist.x64.props" Condition="Exists('packages\cef.redist.x64.3.3396.1786\build\cef.redist.x64.props')" />
<Import Project="packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.props" Condition="Exists('packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.props')" />
<Import Project="packages\CefSharp.Common.69.0.0\build\CefSharp.Common.props" Condition="Exists('packages\CefSharp.Common.69.0.0\build\CefSharp.Common.props')" />
<Import Project="packages\cef.redist.x86.3.3497.1841\build\cef.redist.x86.props" Condition="Exists('packages\cef.redist.x86.3.3497.1841\build\cef.redist.x86.props')" />
<Import Project="packages\cef.redist.x64.3.3497.1841\build\cef.redist.x64.props" Condition="Exists('packages\cef.redist.x64.3.3497.1841\build\cef.redist.x64.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
Expand Down Expand Up @@ -288,15 +288,15 @@
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('packages\cef.redist.x64.3.3396.1786\build\cef.redist.x64.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\cef.redist.x64.3.3396.1786\build\cef.redist.x64.props'))" />
<Error Condition="!Exists('packages\cef.redist.x86.3.3396.1786\build\cef.redist.x86.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\cef.redist.x86.3.3396.1786\build\cef.redist.x86.props'))" />
<Error Condition="!Exists('packages\CefSharp.Common.67.0.0\build\CefSharp.Common.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.Common.67.0.0\build\CefSharp.Common.props'))" />
<Error Condition="!Exists('packages\CefSharp.Common.67.0.0\build\CefSharp.Common.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.Common.67.0.0\build\CefSharp.Common.targets'))" />
<Error Condition="!Exists('packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.props'))" />
<Error Condition="!Exists('packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.targets'))" />
<Error Condition="!Exists('packages\cef.redist.x64.3.3497.1841\build\cef.redist.x64.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\cef.redist.x64.3.3497.1841\build\cef.redist.x64.props'))" />
<Error Condition="!Exists('packages\cef.redist.x86.3.3497.1841\build\cef.redist.x86.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\cef.redist.x86.3.3497.1841\build\cef.redist.x86.props'))" />
<Error Condition="!Exists('packages\CefSharp.Common.69.0.0\build\CefSharp.Common.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.Common.69.0.0\build\CefSharp.Common.props'))" />
<Error Condition="!Exists('packages\CefSharp.Common.69.0.0\build\CefSharp.Common.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.Common.69.0.0\build\CefSharp.Common.targets'))" />
<Error Condition="!Exists('packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.props'))" />
<Error Condition="!Exists('packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.targets'))" />
</Target>
<Import Project="packages\CefSharp.Common.67.0.0\build\CefSharp.Common.targets" Condition="Exists('packages\CefSharp.Common.67.0.0\build\CefSharp.Common.targets')" />
<Import Project="packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.targets" Condition="Exists('packages\CefSharp.WinForms.67.0.0\build\CefSharp.WinForms.targets')" />
<Import Project="packages\CefSharp.Common.69.0.0\build\CefSharp.Common.targets" Condition="Exists('packages\CefSharp.Common.69.0.0\build\CefSharp.Common.targets')" />
<Import Project="packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.targets" Condition="Exists('packages\CefSharp.WinForms.69.0.0\build\CefSharp.WinForms.targets')" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
Expand Down
95 changes: 56 additions & 39 deletions Browser/Main.vb
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@
"-Note Distribution Intervals: " & vbNewLine &
" FoldingCoin: On the 1st Saturday of each month" & vbNewLine &
" CureCoin: Daily. Also, Proof of Stake (POS) when coins are" & vbNewLine &
" over 30 days old, with wallet unlocked and left running." & vbNewLine & vbNewLine &
" over 4 days old, with wallet unlocked and left running." & vbNewLine & vbNewLine &
"-Please contact us on Discord for questions (Use FoldingBrowser Discord buttons)"
FinMsg.Width = (FinMsg.MsgText.Left * 2) + FinMsg.MsgText.Width + 10
FinMsg.Height = (FinMsg.MsgText.Top * 2) + FinMsg.MsgText.Height + FinMsg.btnOK.Height + System.Windows.Forms.SystemInformation.CaptionHeight + System.Windows.Forms.SystemInformation.BorderSize.Height + 30
Expand Down Expand Up @@ -612,46 +612,59 @@

#Region "Button, Checkbox, Combobox - Form Control Events"
Private Async Sub btnFAHWebControl_Click(sender As System.Object, e As System.EventArgs) Handles btnFAHWebControl.Click
'WORKAROUND: The FAH Web Control doesn't always load during the 30 second count down. So, try bypassing it for now. The URL to load without cache doesn't avoiding the other CORS infinite loop error (Refresh without cache still needed)
'Check to see if FAH is running, and if not then pop-up a message to indicate that
Dim bFAHRunning As Boolean = False
Dim bFAH_PageLoaded As Boolean = False
Dim proc As Process
Try
For Each proc In Process.GetProcessesByName(FAH_Client)
bFAHRunning = True
'If you get here, exit searching through the processes
Exit For
Next

If bFAHRunning = False Then
'Indicate FAH is not running
MessageBox.Show("Folding@Home is not running." & vbNewLine & "Please start the Folding@Home software, and try again.", "Folding@Home is not running", MessageBoxButtons.OK, MessageBoxIcon.Information)
End If

Catch ex As Exception
Msg("Error checking if FAH is running: " & ex.ToString)
End Try

'WORKAROUND: The FAH Web Control doesn't always load during the 30 second count down. So, try bypassing it for now. The URL to load without cache doesn't avoiding the other CORS infinite loop error (Refresh without cache still needed)
#Disable Warning BC42358 ' Because this call is not awaited, execution of the current method continues before the call is completed
Dim r As Random = New Random
OpenURL(URL_FAH_WebClient_IPAddr & r.NextDouble.ToString(), False)
#Enable Warning BC42358

'This waits 3 seconds each time, to see if it's going to load quickly. Wait up to 9 seconds total for the page to load
If Await PageTitleWait(FAH_Version) = False AndAlso Await PageTitleWait(FAH_Version) = False AndAlso Await PageTitleWait(FAH_Version) = False Then
'If the user presses a different button to go to a different web page, then don't load the default FAH Web Control URL (can happen easily over the 9 second period, if FAH isn't running)
If Me.txtURL.Text.StartsWith(URL_FAH_WebClient_IPAddr) = True OrElse Me.txtURL.Text = URL_FAH_WebClient_URL Then
'This waits 3 seconds each time, to see if it's going to load quickly. Wait up to 15 seconds total for the page to load
Dim i As Integer = 0
Do Until bFAH_PageLoaded = True OrElse g_bCancelNav = True OrElse i >= 4
i += 1
If Await PageTitleWait(FAH_Version) = True Then bFAH_PageLoaded = True
Loop

'If the user presses a different button to go to a different web page, then don't load the default FAH Web Control URL (can happen easily over the 15 second period, if FAH isn't running)
If bFAH_PageLoaded = False AndAlso (Me.txtURL.Text.StartsWith(URL_FAH_WebClient_IPAddr) = True OrElse Me.txtURL.Text = URL_FAH_WebClient_URL) Then
#Disable Warning BC42358 ' Because this call is not awaited, execution of the current method continues before the call is completed
'If the IP Address version of the page doesn't load, go back to the main URL that has the annoyingly slow 30 countdown page before loading the FAH Web Control
OpenURL(URL_FAH_WebClient_URL, False)
'If the IP Address version of the page doesn't load, go back to the main URL that has the annoyingly slow 30 countdown page before loading the FAH Web Control
OpenURL(URL_FAH_WebClient_URL, False)
#Enable Warning BC42358

'Check to see if FAH is running, and if not then pop-up a message to indicate that
Try
Dim bFAHRunning As Boolean = False
Dim proc As Process
For Each proc In Process.GetProcessesByName(FAH_Client)
bFAHRunning = True
'If you get here, exit searching through the processes
Exit For
Next

If bFAHRunning = True Then
'If FAH is running, then give it a chance for the page to load
If Await PageTitleWait(FAH_Version) = False AndAlso Await PageTitleWait(FAH_Version) = False AndAlso Await PageTitleWait(FAH_Version) = False Then
'If still not loaded, try a Refresh ignoring browser cache
Me.browser.GetBrowser.Reload(True)
End If
Else
'Indicate FAH is not running
MessageBox.Show("Folding@Home is not running." & vbNewLine & "Please start the Folding@Home software, and try again.", "Folding@Home is not running", MessageBoxButtons.OK, MessageBoxIcon.Information)
End If
If bFAHRunning = True Then
'If FAH is running, then give it a chance for the page to load
i = 0
Do Until bFAH_PageLoaded = True OrElse g_bCancelNav = True OrElse i >= 4
i += 1
If Await PageTitleWait(FAH_Version) = True Then bFAH_PageLoaded = True
Loop

Catch ex As Exception
Msg("Error checking if FAH is running: " & ex.ToString)
End Try
'If the user presses a different button to go to a different web page, then don't reload the default FAH Web Control URL (can happen easily over the 15 second period, if FAH isn't running)
If bFAH_PageLoaded = False AndAlso (Me.txtURL.Text.StartsWith(URL_FAH_WebClient_IPAddr) = True OrElse Me.txtURL.Text = URL_FAH_WebClient_URL) Then
'If still not loaded, try a Refresh ignoring browser cache
Me.browser.GetBrowser.Reload(True)
End If
End If
End If
End Sub
Expand Down Expand Up @@ -1011,19 +1024,20 @@
End Sub

Private Sub chkToolsShow_CheckedChanged(sender As System.Object, e As System.EventArgs) Handles chkToolsShow.CheckedChanged
If Me.chkToolsShow.Checked = True Then
'Show Tools Panel
If Me.pnlBtnLinks.Height <= MinPanelHeight Then
'Panel minimized: Show Tools Panel
m_iWebLinkPanelHeight = 360
Me.chkToolsShow.Image = My.Resources.ToolsSettingsGearEnabled_24.ToBitmap
Else
If Me.pnlBtnLinks.Height <= MinPanelHeight Then
'Panel minimized: Show Tools Panel
m_iWebLinkPanelHeight = 360
Me.chkToolsShow.Image = My.Resources.ToolsSettingsGearEnabled_24.ToBitmap
Else
'Panel shown already: Hide Tools Panel
'Panel shown already: Toggle the Tools section
If Me.pnlBtnLinks.Height = 360 Then
'Hide Tools Panel
m_iWebLinkPanelHeight = 260
Me.chkToolsShow.Image = My.Resources.ToolsSettingsGearNoBG_24.ToBitmap
Else
'Show Tools Panel
m_iWebLinkPanelHeight = 360
Me.chkToolsShow.Image = My.Resources.ToolsSettingsGearEnabled_24.ToBitmap
End If
End If

Expand Down Expand Up @@ -3070,6 +3084,9 @@
Try
'Load the web page
If sURL.Length > 0 And Uri.IsWellFormedUriString(sURL, UriKind.RelativeOrAbsolute) = True Then
'Blank out the page title, to allow it to be updated when the page loads for using PageTitleWait()
Me.Text = ""
'Update to the displayed text to the new URL
Me.txtURL.Text = sURL

'Accept Certs to avoid annoying prompts
Expand Down
4 changes: 2 additions & 2 deletions Browser/My Project/AssemblyInfo.vb
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ Imports System.Runtime.InteropServices
' Build Number
' Revision

<Assembly: AssemblyVersion("18.0.0.0")>
<Assembly: AssemblyFileVersion("18.0.0.0")>
<Assembly: AssemblyVersion("19.0.0.0")>
<Assembly: AssemblyFileVersion("19.0.0.0")>
2 changes: 1 addition & 1 deletion Browser/My Project/app.manifest
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
xmlns:asmv3="urn:schemas-microsoft-com:asm.v3"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

<assemblyIdentity version="18.0.0.0" name="FoldingBrowser.app" />
<assemblyIdentity version="19.0.0.0" name="FoldingBrowser.app" />

<!-- Enable themes for Windows common controls and dialogs (Windows XP and later) -->
<dependency>
Expand Down
8 changes: 4 additions & 4 deletions Browser/packages.config
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="cef.redist.x64" version="3.3396.1786" targetFramework="net452" />
<package id="cef.redist.x86" version="3.3396.1786" targetFramework="net452" />
<package id="CefSharp.Common" version="67.0.0" targetFramework="net452" />
<package id="CefSharp.WinForms" version="67.0.0" targetFramework="net452" />
<package id="cef.redist.x64" version="3.3497.1841" targetFramework="net452" />
<package id="cef.redist.x86" version="3.3497.1841" targetFramework="net452" />
<package id="CefSharp.Common" version="69.0.0" targetFramework="net452" />
<package id="CefSharp.WinForms" version="69.0.0" targetFramework="net452" />
</packages>
13 changes: 11 additions & 2 deletions FoldingBrowser - Status - ToDo List.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Immediate Need / Short-Term Goals:
Other Ideas, Improvements, Tasks, Longer-Term Goals:
----------------------------------------------------

-Evaluate upgrading to CefSharp/Chrome v69-v71 (VC++2015) when released here: https://github.com/cefsharp/CefSharp/releases
-Evaluate upgrading to CefSharp/Chrome v70-71 (VC++2015) when released here: https://github.com/cefsharp/CefSharp/releases
-Simple version of the FoldingBrowser: mostly to only run the FAH NaCl Chrome Plugin client (Can the FAH NaCl program be run without a Chrome browser? https://developer.chrome.com/native-client/sdk/download - Also, Chrome NaCl support will be depreciated soon: https://developer.chrome.com/native-client/migration) -Simplicity: Ideally, you only want to enter username and email, and you are up and Folding (as other users have described).
-Use built-in multi-language uninstaller strings for the one non-built-in uninstaller dialog on upgrading? (Ignoring for now)
-Enable Google Translate in Chrome/CefSharp for automatic web page translations?
Expand Down Expand Up @@ -55,14 +55,23 @@ Other Ideas, Improvements, Tasks, Longer-Term Goals:
-Add Option: Dark or light windows & controls theme color options?
-Add support for zooming in on webpages?
-Right-click context menu: Add 'Find' to the list. Also, when highlighting text, add that text to the find dialog?
-Look into issue with CefSharp v67 not always updating the Forward/Back buttons?
-Save more than one log file for debugging issues later?
-Add Web link buttons for Reddit URLs?
-When hovering URLs, display the link at the bottom of the screen?


======================================================================================================
Change Log - Release Notes - Tasks completed:
======================================================================================================

v19 Release (12/24/2018)
[DONE] -Improve Toggle the Tools section
[DONE] -Update CureCoin POS info: 4 day maturity (for v2.0) for staking, instead of 30 day (for v1.9.x.x)
[DONE] -Create CureCoin Wallet v2.0.0.1 installer with the CureCoin Blockchain for easier install for new and upgrading users. (For now, additionally keep the other style installer without the blockchain for any 'FoldingCoin only' people)
[DONE] -Update CureCoin installer to v2.0.0.1
[DONE] -Improve the FAH Web Control page button behavior, where timing issues might cause it to load an extra time.
[DONE] -Upgrade to CefSharp/Chrome v69 (VC++2015)
[DONE] -CureCoin Wallet: Include a 'peers.dat' file for more bootstrap nodes with the CureCoin installer
v18 Release (11/11/2018)
[DONE] -Fixing getting a Passkey at the newer URL
[DONE] -Make an option: Make the button links panel only fly-down when you click on it (It's a bit annoying when you mouse-over it, and you don't want it shown). I like the mouse-enter behavior by default so people know the panel is there, otherwise it's not obvious enough.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ Unicode true ;For all languages to display properly (Installer won't run on Wi

;---- Installer Info ----
Name "${PRODUCT_NAME} v${PRODUCT_VERSION}"
OutFile "Installer\Install-${PRODUCT_NAME}-v${PRODUCT_VERSION}_-_Blockchain_Included.exe"
OutFile "Installer\Install-${PRODUCT_NAME}-v${PRODUCT_VERSION}-Blockchain-Included.exe"
BrandingText "${PRODUCT_PUBLISHER}"
InstallDir "$PROGRAMFILES\${PRODUCT_NAME}" ;Default installation folder (Set to: $INSTDIR during MUI_PAGE_DIRECTORY)
InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
- **FoldingBrowser [Screenshot #1](Screenshot.jpg), [Screenshot #2](Screenshot-LinksMenu.jpg), and [Setup Video](https://www.youtube.com/playlist?list=PLMWSISjQe0XFz9bFy5KXLq4hrgFH-94eI).**
- **Please ask questions on the Discord Contact links below**
- FoldingBrowser is written in VB.NET, compiled with VS2015, targeting the .NET Framework v4.5.2
- Currently based on [cefsharp/67](https://github.com/cefsharp/CefSharp/tree/cefsharp/67) Chrome / Chromium Embedded Framework (CEF)
- Currently based on [cefsharp/69](https://github.com/cefsharp/CefSharp/tree/cefsharp/69) Chrome / Chromium Embedded Framework (CEF)
- Requires: [VC++ 2015 x86 Redist](https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4B285925B00/vc_redist.x86.exe) & [.NET v4.5.2](https://www.microsoft.com/en-us/download/details.aspx?id=42643)
- [Status, release notes, & ideas for future development](FoldingBrowser%20-%20Status%20-%20ToDo%20List.txt)

Expand Down

0 comments on commit 54f5ab3

Please sign in to comment.