Skip to content

Commit

Permalink
Final update for the Updater.exe code.
Browse files Browse the repository at this point in the history
There was something spooky with dwnurl variable so I changed url to
static.
  • Loading branch information
Arkkis committed Aug 5, 2014
1 parent 01d31df commit 8b0b02c
Show file tree
Hide file tree
Showing 7 changed files with 43 additions and 12 deletions.
3 changes: 3 additions & 0 deletions HitboxDashboard/HitboxDashboard.vbproj
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@
<ApplicationManifest>My Project\app.manifest</ApplicationManifest>
</PropertyGroup>
<ItemGroup>
<Reference Include="Alchemy">
<HintPath>..\packages\Alchemy.2.2.1\lib\net40\Alchemy.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\packages\Newtonsoft.Json.6.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
Expand Down
2 changes: 1 addition & 1 deletion HitboxDashboard/MainWindow.Designer.vb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

23 changes: 23 additions & 0 deletions HitboxDashboard/MainWindow.vb
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ Imports System.Text
Imports System.Security.Cryptography
Imports System.Runtime.InteropServices
Imports System.ComponentModel
'Imports Alchemy
'Imports Alchemy.Classes

Public Class MainWindow

Expand All @@ -42,7 +44,19 @@ Public Class MainWindow
Dim sr As StreamReader = Nothing
Dim AutoCompleteGame As New AutoCompleteStringCollection



Public Sub MainWindow_Load(sender As Object, e As EventArgs) Handles MyBase.Load

'Dim ChatSocket As New WebSocketClient("ws://54.204.156.212/socket.io/1/websocket/j26ULqsLWYoTIRtXXKMC")

'ChatSocket.Connect()
'ChatSocket.Send("dada")

'While 1

'End While

If Not File.Exists(inifile) Then
Try
Dim fs As FileStream
Expand Down Expand Up @@ -632,4 +646,13 @@ Public Class MainWindow
Private Sub TextBox_Password_MouseHover(sender As Object, e As EventArgs) Handles TextBox_Password.MouseHover
ToolTip_Password.SetToolTip(TextBox_Password, "Type your Hitbox password here.")
End Sub

'Private Function OnReceive(context As UserContext) As OnEventDelegate
' Throw New NotImplementedException
'End Function

'Private Function OnSend() As OnEventDelegate
' Throw New NotImplementedException
'End Function

End Class
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Dashbox
# Dashbox - No longer updated!

Dashboard management tool for [Hitbox.tv](http://www.hitbox.tv) livestreams. Similar to eg. Twitch Dashboard Lite and other tools but for Hitbox.tv.

Expand Down
15 changes: 8 additions & 7 deletions Updater/Main.vb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Public Class Main

If GblVars.updatedb.Contains("||") Then
array = Split(GblVars.updatedb, "||")
dwnurl = array(0)
dwnurl = "https://832ac22bda8f93ababab398a8cd812b70a6eb164.googledrive.com/host/0BwXzp8oa9Tx4eU93R0xUNkFHa00/"

For i As Integer = 1 To UBound(array) Step +1

Expand All @@ -44,14 +44,15 @@ Public Class Main

Try
File.Delete(path & array(i))
Catch ex As IOException
MsgBox(array(i) & " is in use!")
Catch ex As Exception
MsgBox(array(i) & " is in use!" & vbCrLf & ex.ToString)
End Try

Try
My.Computer.Network.DownloadFile(dwnurl & array(i), path & array(i), "", "", False, 3000, True)
Catch ex As WebException
MsgBox("Can't update " & array(i) & "! File might be read-only or in use!")
'InputBox("", "", dwnurl)
Catch ex As Exception
MsgBox("Can't update " & array(i) & "! File might be read-only or in use!" & vbCrLf & ex.ToString)
End Try
Next
End If
Expand All @@ -76,10 +77,10 @@ Public Class Main
End Class

Public Class GblVars
Public Shared updatedb As String = DownloadString("https://googledrive.com/host/0BwXzp8oa9Tx4eU93R0xUNkFHa00/update.txt")
Public Shared updatedb As String = DownloadString("https://googledrive.com/host/0BwXzp8oa9Tx4eU93R0xUNkFHa00/update.txt").ToString
Public Shared report As String

Shared Function DownloadString(ByVal address As String)
Shared Function DownloadString(ByVal address As String) As String
Dim client As WebClient = New WebClient()
Dim reply As String = client.DownloadString(address)
Return reply
Expand Down
2 changes: 1 addition & 1 deletion Updater/My Project/app.manifest
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
If you want to utilize File and Registry Virtualization for backward
compatibility then delete the requestedExecutionLevel node.
-->
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
</requestedPrivileges>
</security>
</trustInfo>
Expand Down
8 changes: 6 additions & 2 deletions Updater/Updater.vbproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@
<DefineTrace>true</DefineTrace>
<OutputPath>..\HitboxDashboard\bin\Debug\</OutputPath>
<DocumentationFile>Updater.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<NoWarn>41999,42016,42017,42018,42019,42020,42021,42022,42032,42036</NoWarn>
<WarningsAsErrors>
</WarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
Expand All @@ -32,7 +34,9 @@
<Optimize>true</Optimize>
<OutputPath>..\HitboxDashboard\bin\Release\</OutputPath>
<DocumentationFile>Updater.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<NoWarn>41999,42016,42017,42018,42019,42020,42021,42022,42032,42036</NoWarn>
<WarningsAsErrors>
</WarningsAsErrors>
</PropertyGroup>
<PropertyGroup>
<OptionExplicit>On</OptionExplicit>
Expand Down

0 comments on commit 8b0b02c

Please sign in to comment.