Skip to content

Commit cf23e49

Browse files
committed
1 parent a3d1562 commit cf23e49

File tree

2 files changed

+107
-0
lines changed

2 files changed

+107
-0
lines changed

src/Classes/ItemsTab.lua.rej

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
diff a/src/Classes/ItemsTab.lua b/src/Classes/ItemsTab.lua (rejected hunks)
2+
@@ -932,21 +932,11 @@ holding Shift will put it in the second.]])
3+
end)
4+
5+
for i = 1, 20 do
6+
- local prevControl = i == 1 and self.controls.displayItemSectionRange or self.controls["displayItemStackedRangeLine"..(i-1)]
7+
+ local baseControl = i == 1 and self.controls.displayItemSectionRange or self.controls["displayItemStackedRangeSlider"..(i-1)]
8+
9+
- self.controls["displayItemStackedRangeLine"..i] = new("LabelControl", {"TOPLEFT",prevControl,"TOPLEFT"}, {0, function()
10+
+ self.controls["displayItemStackedRangeSlider"..i] = new("SliderControl", {"TOPLEFT",baseControl,"TOPLEFT"}, {0, function()
11+
return i == 1 and 2 or 22
12+
- end, 350, 14}, function()
13+
- if self.displayItem and self.displayItem.rangeLineList[i] then
14+
- return "^7" .. self.displayItem.rangeLineList[i].line
15+
- end
16+
- return ""
17+
- end)
18+
- self.controls["displayItemStackedRangeLine"..i].shown = function()
19+
- return main.showAllItemAffixes and self.displayItem and self.displayItem.rarity == "UNIQUE" and self.displayItem.rangeLineList[i] ~= nil
20+
- end
21+
-
22+
- self.controls["displayItemStackedRangeSlider"..i] = new("SliderControl", {"LEFT",self.controls["displayItemStackedRangeLine"..i],"RIGHT"}, {8, 0, 100, 18}, function(val)
23+
+ end, 100, 18}, function(val)
24+
if self.displayItem and self.displayItem.rangeLineList[i] then
25+
self.displayItem.rangeLineList[i].range = val
26+
self.displayItem:BuildAndParseRaw()
27+
@@ -954,8 +944,18 @@ holding Shift will put it in the second.]])
28+
self:UpdateCustomControls()
29+
end
30+
end)
31+
+ self.controls["displayItemStackedRangeLine"..i] = new("LabelControl", {"LEFT",self.controls["displayItemStackedRangeSlider"..i],"RIGHT"}, {8, -2, 350, 14}, function()
32+
+ if self.displayItem and self.displayItem.rangeLineList[i] then
33+
+ return "^7" .. self.displayItem.rangeLineList[i].line
34+
+ end
35+
+ return ""
36+
+ end)
37+
self.controls["displayItemStackedRangeSlider"..i].shown = function()
38+
- return self.controls["displayItemStackedRangeLine"..i]:IsShown()
39+
+ return main.showAllItemAffixes and self.displayItem and self.displayItem.rarity == "UNIQUE" and self.displayItem.rangeLineList[i] ~= nil
40+
+ end
41+
+
42+
+ self.controls["displayItemStackedRangeLine"..i].shown = function()
43+
+ return self.controls["displayItemStackedRangeSlider"..i]:IsShown()
44+
end
45+
end
46+

src/Modules/Main.lua.rej

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
diff a/src/Modules/Main.lua b/src/Modules/Main.lua (rejected hunks)
2+
@@ -113,8 +113,8 @@ function main:Init()
3+
self.showPublicBuilds = true
4+
self.showFlavourText = true
5+
self.showAnimations = true
6+
- self.errorReadingSettings = false
7+
- self.showAllItemAffixes = false
8+
+ self.showAllItemAffixes = true
9+
+ self.errorReadingSettings = false
10+
11+
if not SetDPIScaleOverridePercent then SetDPIScaleOverridePercent = function(scale) end end
12+
13+
@@ -655,10 +655,10 @@ function main:LoadSettings(ignoreBuild)
14+
if node.attrib.showFlavourText then
15+
self.showFlavourText = node.attrib.showFlavourText == "true"
16+
end
17+
- if node.attrib.showAnimations then
18+
+ if node.attrib.showAnimations then
19+
self.showAnimations = node.attrib.showAnimations == "true"
20+
end
21+
- if node.attrib.showAllItemAffixes then
22+
+ if node.attrib.showAllItemAffixes then
23+
self.showAllItemAffixes = node.attrib.showAllItemAffixes == "true"
24+
end
25+
if node.attrib.dpiScaleOverridePercent then
26+
@@ -794,7 +794,7 @@ function main:SaveSettings()
27+
showPublicBuilds = tostring(self.showPublicBuilds),
28+
showFlavourText = tostring(self.showFlavourText),
29+
showAnimations = tostring(self.showAnimations),
30+
- showAllItemAffixes = tostring(self.showAllItemAffixes),
31+
+ showAllItemAffixes = tostring(self.showAllItemAffixes),
32+
dpiScaleOverridePercent = tostring(self.dpiScaleOverridePercent),
33+
} })
34+
local res, errMsg = common.xml.SaveXMLFile(setXML, self.userPath.."Settings.xml")
35+
@@ -1099,7 +1099,7 @@ function main:OpenOptionsPopup()
36+
controls.showPublicBuilds.state = self.showPublicBuilds
37+
controls.showFlavourText.state = self.showFlavourText
38+
controls.showAnimations.state = self.showAnimations
39+
- controls.showAllItemAffixes.state = self.showAllItemAffixes
40+
+ controls.showAllItemAffixes.state = self.showAllItemAffixes
41+
local initialNodePowerTheme = self.nodePowerTheme
42+
local initialColorPositive = self.colorPositive
43+
local initialColorNegative = self.colorNegative
44+
@@ -1121,7 +1121,7 @@ function main:OpenOptionsPopup()
45+
local initialShowPublicBuilds = self.showPublicBuilds
46+
local initialShowFlavourText = self.showFlavourText
47+
local initialShowAnimations = self.showAnimations
48+
- local initialShowAllItemAffixes = self.showAllItemAffixes
49+
+ local initialShowAllItemAffixes = self.showAllItemAffixes
50+
local initialDpiScaleOverridePercent = self.dpiScaleOverridePercent
51+
52+
-- last line with buttons has more spacing
53+
@@ -1177,7 +1177,7 @@ function main:OpenOptionsPopup()
54+
self.showPublicBuilds = initialShowPublicBuilds
55+
self.showFlavourText = initialShowFlavourText
56+
self.showAnimations = initialShowAnimations
57+
- self.showAllItemAffixes = initialShowAllItemAffixes
58+
+ self.showAllItemAffixes = initialShowAllItemAffixes
59+
self.dpiScaleOverridePercent = initialDpiScaleOverridePercent
60+
SetDPIScaleOverridePercent(self.dpiScaleOverridePercent)
61+
main:ClosePopup()

0 commit comments

Comments
 (0)