Skip to content

Commit

Permalink
Merge pull request #360 from stevieb9/ui_layout_automation
Browse files Browse the repository at this point in the history
UI layout automation
  • Loading branch information
stevieb9 authored Aug 7, 2023
2 parents b17441d + 44da0a8 commit ceefc61
Show file tree
Hide file tree
Showing 10 changed files with 1,208 additions and 315 deletions.
7 changes: 5 additions & 2 deletions Changes
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
Revision history for berrybrew

1.42 UNREL
-

- Added `dev/ui_simulator.pl`, a non-functioning layout simulator which on
the click of any button, reloads the window after loading in updated
config elements from the `data/ui.json` config file (closes #358)
- Added new UI layout manipulation scripts and tools
- Updated development documentation for new UI tools

1.41 2023-08-03
- Renamed `PerlOp.PerlOrphansIgnore()` to `Berrybrew.SpecialInstanceDirectories()`
Expand Down
4 changes: 2 additions & 2 deletions dev/build_staging_ui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ call perl -i.bak -ne "s/\"run_mode\"\s+:\s+\"prod\"/\"run_mode\"\t\t : \"stagin

echo "compiling UI..."

call csc^
call mcs^
src\berrybrew-ui.cs^
src\perloperations.cs^
-lib:staging^
Expand All @@ -23,4 +23,4 @@ call csc^
-r:Newtonsoft.Json.dll^
-win32icon:inc/berrybrew.ico^
-win32manifest:berrybrew.manifest^
-out:staging/berrybrew-ui.exe^
-out:staging/berrybrew-ui.exe
262 changes: 262 additions & 0 deletions dev/data/ui.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,262 @@
{
"checkbox" : {
"windowsHomedir" : {
"width" : 200,
"autosize" : true,
"location" : [
10,
295
],
"text" : "Windows homedir"
},
"powershell" : {
"width" : 200,
"location" : [
10,
235
],
"text" : "Use Powershell",
"autosize" : true
},
"warnOrphans" : {
"width" : 200,
"autosize" : true,
"text" : "Warn on orphans",
"location" : [
10,
275
]
},
"debug" : {
"location" : [
10,
215
],
"text" : "Debug",
"autosize" : true,
"width" : 200
},
"fileAssoc" : {
"width" : 200,
"autosize" : true,
"location" : [
10,
255
],
"text" : "Manage file association"
}
},
"label" : {
"currentPerl" : {
"location" : [
10,
10
],
"text" : "Current Perl: None Configured",
"index" : 1,
"name" : "BBUI",
"size" : [
159,
20
],
"tabindex" : 0,
"autosize" : true
}
},
"ui_simulator" : {
"font_size" : 11
},
"ui_object" : {
"client_size" : [
265,
325
],
"trayicon_text" : "berrybrew UI"
},
"button" : {
"perlFetch" : {
"index" : 8,
"name" : "perlFetchButton",
"text" : "Fetch",
"location" : [
10,
185
],
"size" : [
75,
23
],
"tabindex" : 1
},
"perlSwitch" : {
"size" : [
75,
23
],
"name" : "perlSwitchButton",
"index" : 3,
"tabindex" : 1,
"location" : [
139,
35
],
"text" : "Switch"
},
"perlOff" : {
"size" : [
35,
20
],
"index" : 2,
"name" : "perlOffButton",
"location" : [
215,
10
],
"text" : "Off",
"tabindex" : 1
},
"perlOpen" : {
"size" : [
45,
20
],
"tabindex" : 1,
"index" : 1,
"name" : "perlOpenButton",
"text" : "Open",
"location" : [
169,
10
]
},
"perlUse" : {
"size" : [
75,
23
],
"location" : [
139,
95
],
"text" : "Use",
"index" : 5,
"name" : "perlUseButton",
"tabindex" : 1
},
"perlInstall" : {
"size" : [
75,
23
],
"text" : "Install",
"location" : [
139,
65
],
"index" : 4,
"name" : "perlInstallButton",
"tabindex" : 1
},
"perlClone" : {
"tabindex" : 1,
"text" : "Clone",
"location" : [
139,
155
],
"name" : "perlCloneButton",
"index" : 7,
"size" : [
75,
23
]
},
"perlRemove" : {
"tabindex" : 1,
"name" : "perlRemoveButton",
"index" : 6,
"location" : [
139,
125
],
"text" : "Remove",
"size" : [
75,
23
]
}
},
"combobox" : {
"perlClone" : {
"location" : [
10,
155
],
"tabindex" : 0,
"name" : "perlCloneSelect",
"index" : 5,
"size" : [
121,
30
],
"formatting_enabled" : true
},
"perlInstall" : {
"formatting_enabled" : true,
"size" : [
121,
30
],
"location" : [
10,
65
],
"tabindex" : 0,
"index" : 2,
"name" : "perlInstallSelect"
},
"perlUse" : {
"formatting_enabled" : true,
"size" : [
121,
30
],
"index" : 3,
"name" : "perlUseSelect",
"tabindex" : 0,
"location" : [
10,
95
]
},
"perlSwitch" : {
"location" : [
10,
35
],
"name" : "perlSwitchSelect",
"index" : 1,
"size" : [
121,
30
],
"tabindex" : 0,
"formatting_enabled" : true
},
"perlRemove" : {
"size" : [
121,
30
],
"formatting_enabled" : true,
"location" : [
10,
125
],
"name" : "perlRemoveSelect",
"index" : 4,
"tabindex" : 0
}
}
}
Loading

0 comments on commit ceefc61

Please sign in to comment.