Skip to content

Commit

Permalink
Merge branch 'release/1.6'
Browse files Browse the repository at this point in the history
  • Loading branch information
ktekinay committed Aug 18, 2015
2 parents df85cb9 + fd36d85 commit a2ca3b1
Show file tree
Hide file tree
Showing 31 changed files with 4,030 additions and 55 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Expand Up @@ -4,3 +4,6 @@ Update Test App/Builds - Kaju Update Test.xojo_project
DebugKaju Update Test.tar.gz
DebugKaju Admin.tar.gz
Kaju Admin App/Builds - Kaju Admin.xojo_project
Kaju Admin CLI/kaju.debug
Kaju Admin CLI/Builds - Kaju Admin CLI.xojo_project
*.gz
Expand Up @@ -19,7 +19,7 @@ Protected Class KajuFile
#tag EndMethod

#tag Method, Flags = &h0
Sub ExportTo(f As FolderItem)
Sub ExportTo(fileOrFolder As FolderItem)
dim data as JSONItem = DataToJSON
data.Compact = false
data.EscapeSlashes = false
Expand Down Expand Up @@ -51,15 +51,50 @@ Protected Class KajuFile

dataString = Kaju.kUpdatePacketMarker + sig + EndOfLine.UNIX + dataString

//
// If it's a folder, get the child
//
dim f as FolderItem = fileOrFolder
if f.Directory then
f = f.Child( ExportFilename )
end if

dim tos as TextOutputStream = TextOutputStream.Create( f )
tos.Write dataString
tos.Close
tos = nil

mExportFilename = f.Name

End Sub
#tag EndMethod

#tag Method, Flags = &h0
Function GetVersion(version As String) As Kaju.UpdateInformation
dim i as integer = IndexOf( version )
if i <> -1 then
return KajuData( i )
else
return nil
end if
End Function
#tag EndMethod

#tag Method, Flags = &h0
Function IndexOf(version As String) As Integer
version = version.Trim

for i as integer = 0 to KajuData.Ubound
dim u as Kaju.UpdateInformation = KajuData( i )
if u.Version.Trim = version then
return i
end if
next

return -1
End Function
#tag EndMethod

#tag Method, Flags = &h0
Shared Function InsertVersion(originalURL As String, version As String) As String
return originalURL.ReplaceAllB( "$VERSION$", version )
Expand Down Expand Up @@ -155,8 +190,8 @@ Protected Class KajuFile
KajuData() As Kaju.UpdateInformation
#tag EndProperty

#tag Property, Flags = &h0
mExportFilename As String = "UpdateInformation.json"
#tag Property, Flags = &h21
Private mExportFilename As String = "UpdateInformation.json"
#tag EndProperty

#tag Property, Flags = &h21
Expand Down Expand Up @@ -216,12 +251,6 @@ Protected Class KajuFile
InitialValue="0"
Type="Integer"
#tag EndViewProperty
#tag ViewProperty
Name="mExportFilename"
Group="Behavior"
InitialValue="UpdateInformation.json"
Type="String"
#tag EndViewProperty
#tag ViewProperty
Name="Name"
Visible=true
Expand Down
12 changes: 6 additions & 6 deletions Kaju Admin App/Kaju Admin.xojo_project
@@ -1,5 +1,5 @@
Type=Desktop
RBProjectVersion=2015.022
RBProjectVersion=2015.023
MinIDEVersion=20070100
Folder=Kaju Classes;../Kaju Classes;&h2570CF64;&h0;false
Class=App;App.xojo_code;&h7955649;&h0;false
Expand All @@ -26,16 +26,16 @@ Class=CheckBoxChanger;Controls/CheckBoxChanger.xojo_code;&h5115CD40;&hE8B14E5;fa
Class=FolderItemAlias;Other Classes/FolderItemAlias.xojo_code;&h53EF1AE5;&h6AF5D169;false
Class=HTTPSSocket;../Kaju Classes/Kaju/HTTPSSocket.xojo_code;&h5ACDFAEB;&h11400316;false
Plist=Info;Custom Plist/Info.plist;&h7393D7FF;&h74C1A7FF;false
Class=KajuFile;KajuFile.xojo_code;&h1A7FF7FF;&h0;false
Class=KajuFile;../Admin Classes/KajuFile.xojo_code;&h1A7FF7FF;&h0;false
AppMenuBar=MainMenuBar
MajorVersion=1
MinorVersion=5
SubVersion=3
MinorVersion=6
SubVersion=0
NonRelease=0
Release=3
InfoVersion=Kaju Admin
LongVersion=v.1.5.3
ShortVersion=1.5.3
LongVersion=v.1.6
ShortVersion=1.6
WinCompanyName=MacTechnologies Consulting
WinInternalName=
WinProductName=
Expand Down
44 changes: 19 additions & 25 deletions Kaju Admin App/WndAdmin.xojo_window
Expand Up @@ -202,7 +202,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 12
TabPanelIndex = 0
TabStop = True
Text = "Version:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -337,7 +336,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 11
TabPanelIndex = 1
TabStop = True
Text = "Preview:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -447,7 +445,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 12
TabPanelIndex = 2
TabStop = True
Text = "Hash:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -482,7 +479,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 13
TabPanelIndex = 2
TabStop = True
Text = "URL:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -517,7 +513,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 10
TabPanelIndex = 1
TabStop = True
Text = "Release Notes (HTML):"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -627,7 +622,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 15
TabPanelIndex = 2
TabStop = True
Text = "Hash:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -662,7 +656,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 16
TabPanelIndex = 2
TabStop = True
Text = "URL:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -729,7 +722,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 18
TabPanelIndex = 2
TabStop = True
Text = "Hash:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -764,7 +756,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 19
TabPanelIndex = 2
TabStop = True
Text = "URL:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -842,7 +833,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 3
TabPanelIndex = 3
TabStop = True
Text = "URL:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -974,7 +964,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 20
TabPanelIndex = 2
TabStop = True
Text = "Minimum Required Version:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -1401,7 +1390,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 14
TabPanelIndex = 2
TabStop = True
Text = "Executable:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -1479,7 +1467,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 17
TabPanelIndex = 2
TabStop = True
Text = "Executable:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -1782,7 +1769,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 21
TabPanelIndex = 2
TabStop = True
Text = "Use ‘$VERSION$’ in the URL to insert the version on export"
TextAlign = 1
TextColor = &c00000000
Expand Down Expand Up @@ -1860,7 +1846,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 11
TabPanelIndex = 0
TabStop = True
Text = "App Name:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -1906,8 +1891,7 @@ Begin Window WndAdmin
Width = 180
End
Begin Timer tmrUpdateReleaseNotesPreview
Enabled = True
Height = "32"
Height = 32
Index = -2147483648
InitialParent = ""
Left = 0
Expand All @@ -1917,8 +1901,7 @@ Begin Window WndAdmin
Scope = 2
TabPanelIndex = 0
Top = 0
Visible = True
Width = "32"
Width = 32
End
Begin HTMLViewer hvNewWindow
AutoDeactivate = True
Expand Down Expand Up @@ -1973,8 +1956,7 @@ Begin Window WndAdmin
Width = 186
End
Begin Timer tmrUpdateImagePreview
Enabled = True
Height = "32"
Height = 32
Index = -2147483648
InitialParent = ""
Left = 20
Expand All @@ -1984,8 +1966,7 @@ Begin Window WndAdmin
Scope = 2
TabPanelIndex = 0
Top = 20
Visible = True
Width = "32"
Width = 32
End
Begin Label lblPlatform
AutoDeactivate = True
Expand All @@ -2009,7 +1990,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 14
TabPanelIndex = 0
TabStop = True
Text = "None"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -2044,7 +2024,6 @@ Begin Window WndAdmin
Selectable = False
TabIndex = 13
TabPanelIndex = 0
TabStop = True
Text = "Platforms:"
TextAlign = 0
TextColor = &c00000000
Expand Down Expand Up @@ -2451,7 +2430,20 @@ End
return
end if

StoreFieldsToVersionRow

dim version as Kaju.UpdateInformation = lbVersions.RowTag( curIndex )

dim dlg as new MessageDialog
dlg.Message = "Really delete version " + version.Version + "?"
dlg.Explanation = "This cannot be undone."
dlg.ActionButton.Caption = "&Delete"
dlg.CancelButton.Visible = true
dim btn as MessageDialogButton = dlg.ShowModalWithin( self )
if btn is dlg.CancelButton then
return
end if

lbVersions.ListIndex = -1
lbVersions.RemoveRow( curIndex )

Expand All @@ -2464,6 +2456,8 @@ End
if curIndex < lbVersions.ListCount then
lbVersions.ListIndex = curIndex
end if

ContentsChanged = true
End Sub
#tag EndMethod

Expand Down

0 comments on commit a2ca3b1

Please sign in to comment.